pygieons documentationΒΆ

What is pygieons?ΒΆ

The name (you would anyway ask πŸ˜‰): Python GIS and Earch Observation Networks

As described elsewhere, this website is largely generated automatically by using a Python tool called pygieons. This tool auto-generates content regarding the listed packages and adds them to the website either as tables or interactive Network visualizations. pygieons is currently focused on parsing information about Python GIS and Earth Observation libraries, but it is a rather generic tool, with modest modifications it would be possible to parse and visualize information from any collection of libraries available on PyPi.

pygieons is largely based on pandas which is used for data manipulation, while pyvis library is used to visualize the connections between libraries as an interactive network of links. In addition, under the hood libraries such as requests, beautifulsoup4 and pypistats are used to extract relevant information about the listed libraries from the PyPi web pages.

Below, we demonstrate some basic functionalities that can be used to auto-generate content using pygieons.

Basic usageΒΆ

Initializing the toolΒΆ

To generate content with pygieons, you need to first initialize the tool with Ecosystem() object which accepts a parameter plot_type that can be used to define which category of libraries we want to plot, and parameter log which can be used to disable logging to the screen. Below is the slightly modified output from help(Ecosystem) command showing information about how the tool can be initialized:

class Ecosystem(builtins.object)
 |  Ecosystem(plot_type='all', keep_all=False, log=True)
 |        
 |      Parameters
 |      ==========
 |      
 |      plot_type : str
 |          This can be used to specify if you want to plot all packages in same figure, or only vector or raster.
 |          Possible values are: "all", "vector", "raster", "generic", "vector+generic", "raster+generic".
 |      keep_all : bool
 |          If True, also packages that are not available from PyPi or which are not maintained will be kept.
 |      log: bool
 |          If True, will print messages during process.
  • Let’s initialize the tool and configure it for plotting raster libraries.

from pygieons import Ecosystem

# Initialize the tool 
e = Ecosystem(plot_type="raster", log=True)

Generating tablesΒΆ

To generate a table showing various information about the libraries, you can use method prepare_table(), which autogenerates the table contents based on the packages listed in ecosystem_connections.py and ecosystem_pkgs.py files. The tool will print out information about the progress if log was specified as True:

# Generate the content
tbl = e.prepare_table()
Find out the number of monthly downloads from PyPi for the libraries ..
Extract project details ..
  • You can visualize the table by calling .show() of the returned Table object:

tbl.show()
Analysis / modelling (count=9)
Name Homepage Info License PyPi version PyPi downloads (monthly) Conda-forge version Conda-forge downloads Conda-forge latest release
gstools 🏠 β“˜ License PyPI version 1,668 Conda version Conda downloads Conda latest release
pykrige 🏠 β“˜ License PyPI version 17,754 Conda version Conda downloads Conda latest release
pysheds 🏠 β“˜ License PyPI version 925 Conda version Conda downloads Conda latest release
pyspatialml 🏠 β“˜ NA PyPI version 78 NA NA NA
rasterstats 🏠 β“˜ License PyPI version 61,113 Conda version Conda downloads Conda latest release
richdem 🏠 β“˜ License PyPI version 2,187 Conda version Conda downloads Conda latest release
scikit-learn 🏠 β“˜ License PyPI version 31,705,557 Conda version Conda downloads Conda latest release
spyndex 🏠 β“˜ License PyPI version 287 Conda version Conda downloads Conda latest release
xarray-spatial 🏠 β“˜ License PyPI version 1,843 Conda version Conda downloads Conda latest release
Core / data structures (count=8)
Name Homepage Info License PyPi version PyPi downloads (monthly) Conda-forge version Conda-forge downloads Conda-forge latest release
affine 🏠 β“˜ License PyPI version 669,468 Conda version Conda downloads Conda latest release
iris 🏠 β“˜ License PyPI version 948 Conda version Conda downloads Conda latest release
rasterio 🏠 β“˜ License PyPI version 744,408 Conda version Conda downloads Conda latest release
rio-cogeo 🏠 β“˜ License PyPI version 13,656 Conda version Conda downloads Conda latest release
rioxarray 🏠 β“˜ License PyPI version 38,468 Conda version Conda downloads Conda latest release
sarpy 🏠 β“˜ License PyPI version 911 Conda version Conda downloads Conda latest release
sarsen 🏠 β“˜ License PyPI version 40 Conda version Conda downloads Conda latest release
xarray 🏠 β“˜ License PyPI version 1,626,657 Conda version Conda downloads Conda latest release
Data extraction / processing (count=22)
Name Homepage Info License PyPi version PyPi downloads (monthly) Conda-forge version Conda-forge downloads Conda-forge latest release
earthengine-api 🏠 β“˜ License PyPI version 32,896 Conda version Conda downloads Conda latest release
easystac 🏠 β“˜ License PyPI version 87 Conda version Conda downloads Conda latest release
eemont 🏠 β“˜ License PyPI version 598 Conda version Conda downloads Conda latest release
eoreader 🏠 β“˜ License PyPI version 434 Conda version Conda downloads Conda latest release
lidar 🏠 β“˜ License PyPI version 279 Conda version Conda downloads Conda latest release
odc-stac 🏠 β“˜ License PyPI version 849 Conda version Conda downloads Conda latest release
planetary-computer 🏠 β“˜ License PyPI version 2,874 Conda version Conda downloads Conda latest release
pymap3d 🏠 β“˜ License PyPI version 43,146 Conda version Conda downloads Conda latest release
pyrosar 🏠 β“˜ License PyPI version 478 Conda version Conda downloads Conda latest release
pystac 🏠 β“˜ License PyPI version 31,727 Conda version Conda downloads Conda latest release
pystac-client 🏠 β“˜ License PyPI version 9,996 Conda version Conda downloads Conda latest release
radiant-mlhub 🏠 β“˜ License PyPI version 6,902 Conda version Conda downloads Conda latest release
rio-hist 🏠 β“˜ NA PyPI version 168 NA NA NA
rio-mucho 🏠 β“˜ License PyPI version 8,470 Conda version Conda downloads Conda latest release
rio-tiler 🏠 β“˜ License PyPI version 8,373 Conda version Conda downloads Conda latest release
salem 🏠 β“˜ License PyPI version 4,972 Conda version Conda downloads Conda latest release
satpy 🏠 β“˜ License PyPI version 3,841 Conda version Conda downloads Conda latest release
sentinelsat 🏠 β“˜ License PyPI version 12,338 Conda version Conda downloads Conda latest release
stackstac 🏠 β“˜ License PyPI version 1,142 Conda version Conda downloads Conda latest release
verde 🏠 β“˜ License PyPI version 729 Conda version Conda downloads Conda latest release
xarray-sentinel 🏠 β“˜ License PyPI version 70 Conda version Conda downloads Conda latest release
xyzservices 🏠 β“˜ License PyPI version 164,884 Conda version Conda downloads Conda latest release
Visualization (count=4)
Name Homepage Info License PyPi version PyPi downloads (monthly) Conda-forge version Conda-forge downloads Conda-forge latest release
contextily 🏠 β“˜ License PyPI version 64,948 Conda version Conda downloads Conda latest release
pyvista-xarray 🏠 β“˜ NA PyPI version 362 NA NA NA
rio-color 🏠 β“˜ License PyPI version 8,260 Conda version Conda downloads Conda latest release
xarray_leaflet 🏠 β“˜ License PyPI version 848 Conda version Conda downloads Conda latest release

Generating Network visualizationΒΆ

To generate an interactive network visualization showing the connections between libraries, you can use method prepare_net(), which autogenerates the Network based on the packages listed in ecosystem_connections.py file. The tool will print out information about the progress if log was specified as True:

# Generate the content
net = e.prepare_net()
  • You can visualize the network by calling .show() of the returned Network object

net.show()

  • In addition, you can also save the Network visualization as a HTML file to your own computer by calling .save() method:

net.save("test.html")