A toolbox for processing earth observation data with Python.

Related tags

Geolocationeo-box
Overview

Build Status Docs Status

eo-box

eobox is a Python package with a small collection of tools for working with Remote Sensing / Earth Observation data.

Package Overview

So far, the following subpackages are available:

  • eobox.sampledata contains small sample data that can be used for playing around and testing.

  • eobox.raster contains raster processing tools for

    • extracting raster values at given (by vector data) locations,

    • window- / chunk-wise processing of multiple single layer raster files that do not fit in memory, e.g.

      • calculating virtual time series and temporal statistical metrics from all cloud-free observations,

      • predicting a machine learning model,

      • custom processing functions.

  • eobox.vector contains vector processing tools for

    • clean convertion of polygons to lines and

    • distance-to-polygon border calculation.

  • eobox.ml contains machine learning related tools, e.g.

    • plotting a confusion matrix including with precision and recall

    • extended predict function which returns prediction, confidences, and probabilities.

Installation

The package requires Python 3. It can be installed with the following command:

pip install eobox

The environment.yaml in the repository can be used to setup a conda environment with all dependencies required for using and building the package and running the tests and documentation code.

conda env create --name=eobox --file=environment.yml
pip install eobox

Documentation

The package documentation can be found at readthedocs.

Comments
  • Module convert_df_to_geodf not found

    Module convert_df_to_geodf not found

    hi @benmack. I am having an issue (I am using eobox version 0.3.1.). Python version 3.6.10. I can import fine eobox.

    import convert_df_to_geodf

    Error

    ---------------------------------------------------------------------------
    ModuleNotFoundError                       Traceback (most recent call last)
    <ipython-input-22-bb79235e32c0> in <module>
    ----> 1 import convert_df_to_geodf
    
    ModuleNotFoundError: No module named 'convert_df_to_geodf'
    

    Thank you!

    opened by elsadg 2
  • Change the internal package structure back to standard

    Change the internal package structure back to standard

    from v0.0.3 onwards the package will have a simple structure again, i.e. it will not be possible to install the sub-pacakges independently. I started to set it up like this to learn and understand, however it makes it more difficult to extend and maintain the package and since it is rather a playground and learning package the easier way seems better to me now.

    So Up to v0.0.2 you read this in the READMY:

    The structure of this project has been created following the eo-learn project of Sinergise. For a package containing diverse functionalities as it is envisaged for this package as well, it is convincing to subdivide the pacakge into "several subpackages according to different functionalities and external package dependencies".

    But that will change.

    enhancement 
    opened by benmack 1
  • error when running extraction

    error when running extraction

    Hello, I want to want to do pixel-based processing with eo-box. I am following the blog post in https://benmack.github.io/blog/2020-01-06-1_federsee-blog-series_part-3_clf/ to do so. I have one tif image and a shapefile with some polygons (same projection). The error I get when I run the extraction is the following:

    CalledProcessError: Command 'C:\DIR\lib\site-packages\GDAL-3.1.4-py3.7-win-amd64.egg-info\scripts\gdal_proximity.py C:\DIR\TEMPDIR_aux_vector_dist2pb_5yp1nyvy\interim_sample_vector_dataset_lines.tif C:\DIR\aux_vector_dist2pb.tif -ot Float32 -distunits PIXEL -values 1 -maxdist 255' returned non-zero exit status 1.

    Any idea what might be wrong?

    opened by Sananvalinta 1
  • Create docker image to handle non-root users

    Create docker image to handle non-root users

    Build a docker image for running jupyterlab in a container with a non-root user, e.g.

    docker run -u $(id -u $USER):$(id -g $USER) -v ${PWD}:/home/eoboxer/lucas-hls -p 8888:8888 benmack/eobox:latest

    This is currently not possible and throws an exeption (see below).

    The problem is that on the one hand we need a geospatial setup on the other hand we need a proper jupyter setup. Both can be tricky. Options for base images:

    • https://github.com/OSGeo/gdal - relatively slim geo option
    • https://jupyter-docker-stacks.readthedocs.io/en/latest/ - slim jupyter options
    • https://github.com/SCiO-systems/cgspatial-notebook - very large option that might contain both

    Current exception

    docker run -u $(id -u $USER):$(id -g $USER) -v ${PWD}:/home/eoboxer/lucas-hls -p 8888:8888 benmack/eobox:latest
    Traceback (most recent call last):
      File "/usr/local/lib/python3.8/dist-packages/traitlets/traitlets.py", line 528, in get
        value = obj._trait_values[self.name]
    KeyError: 'runtime_dir'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "/usr/local/bin/jupyter-notebook", line 8, in <module>
        sys.exit(main())
      File "/usr/local/lib/python3.8/dist-packages/jupyter_core/application.py", line 270, in launch_instance
        return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
      File "/usr/local/lib/python3.8/dist-packages/traitlets/config/application.py", line 663, in launch_instance
        app.initialize(argv)
      File "<decorator-gen-7>", line 2, in initialize
      File "/usr/local/lib/python3.8/dist-packages/traitlets/config/application.py", line 87, in catch_config_error
        return method(app, *args, **kwargs)
      File "/usr/local/lib/python3.8/dist-packages/notebook/notebookapp.py", line 1766, in initialize
        self.init_configurables()
      File "/usr/local/lib/python3.8/dist-packages/notebook/notebookapp.py", line 1380, in init_configurables
        connection_dir=self.runtime_dir,
      File "/usr/local/lib/python3.8/dist-packages/traitlets/traitlets.py", line 556, in __get__
        return self.get(obj, cls)
      File "/usr/local/lib/python3.8/dist-packages/traitlets/traitlets.py", line 535, in get
        value = self._validate(obj, dynamic_default())
      File "/usr/local/lib/python3.8/dist-packages/jupyter_core/application.py", line 100, in _runtime_dir_default
        ensure_dir_exists(rd, mode=0o700)
      File "/usr/local/lib/python3.8/dist-packages/jupyter_core/utils/__init__.py", line 13, in ensure_dir_exists
        os.makedirs(path, mode=mode)
      File "/usr/lib/python3.8/os.py", line 213, in makedirs
        makedirs(head, exist_ok=exist_ok)
      File "/usr/lib/python3.8/os.py", line 213, in makedirs
        makedirs(head, exist_ok=exist_ok)
      File "/usr/lib/python3.8/os.py", line 213, in makedirs
        makedirs(head, exist_ok=exist_ok)
      File "/usr/lib/python3.8/os.py", line 223, in makedirs
        mkdir(name, mode)
    PermissionError: [Errno 13] Permission denied: '/.local'
    
    opened by benmack 0
  • Extraction: store user-given numeric columns from vector file as pixel level .npy file

    Extraction: store user-given numeric columns from vector file as pixel level .npy file

    This makes sense since at the moment we only store the polygon ID but usually we want to frequently work with at least the class ID which we have stored in the vector file.

    At the moment the user has to join that data on the pixel level by himself. But we could do that in the extraction function or provide as a separate function which works on top of an existing extraction folder.

    enhancement 
    opened by benmack 0
  • Implement EOCubeSceneCollection method for statistical metrics

    Implement EOCubeSceneCollection method for statistical metrics

    Practically we only need to wrap what ther is already in ./examples/raster/cube_custom_functions_with_eocubescenecollection.ipynb in a method like EOCubeSceneCollection.create_virtual_time_series

    enhancement 
    opened by benmack 0
  • Create Intro to EOCubeSceneCollection class

    Create Intro to EOCubeSceneCollection class

    See what parts are useful of the following ones:

    • ./examples/raster/cube_calculate_virtual_time_series_with_eocube.ipynb

    • ./examples/raster/cube_eocubescenecollection_and_virtual_time_series.ipynb

    documentation 
    opened by benmack 0
A set of utility functions for working with GeoJSON annotations in Kaibu

kaibu-utils A set of utility functions for working with Kaibu. Create a new repository Create a new repository and select imjoy-team/imjoy-python-temp

ImJoy Team 0 Dec 12, 2021
Geocoding library for Python.

geopy geopy is a Python client for several popular geocoding web services. geopy makes it easy for Python developers to locate the coordinates of addr

geopy 3.8k Dec 30, 2022
A modern, geometric typeface by @chrismsimpson (last commit @ 85fa625 Jun 9, 2020 before deletion)

Metropolis A modern, geometric typeface. Influenced by other popular geometric, minimalist sans-serif typefaces of the new millenium. Designed for opt

Darius 183 Dec 25, 2022
GebPy is a Python-based, open source tool for the generation of geological data of minerals, rocks and complete lithological sequences.

GebPy is a Python-based, open source tool for the generation of geological data of minerals, rocks and complete lithological sequences. The data can be generated randomly or with respect to user-defi

Maximilian Beeskow 16 Nov 29, 2022
A proof-of-concept jupyter extension which converts english queries into relevant python code

Text2Code for Jupyter notebook A proof-of-concept jupyter extension which converts english queries into relevant python code. Blog post with more deta

DeepKlarity 2.1k Dec 29, 2022
A part of HyRiver software stack for handling geospatial data manipulations

Package Description Status PyNHD Navigate and subset NHDPlus (MR and HR) using web services Py3DEP Access topographic data through National Map's 3DEP

Taher Chegini 5 Dec 14, 2022
A Python interface between Earth Engine and xarray

eexarray A Python interface between Earth Engine and xarray Description eexarray was built to make processing gridded, mesoscale time series data quic

Aaron Zuspan 159 Dec 23, 2022
Read images to numpy arrays

mahotas-imread: Read Image Files IO with images and numpy arrays. Mahotas-imread is a simple module with a small number of functions: imread Reads an

Luis Pedro Coelho 67 Jan 07, 2023
Ingest and query genomic intervals from multiple BED files

Ingest and query genomic intervals from multiple BED files.

4 May 29, 2021
Geographic add-ons for Django REST Framework. Maintained by the OpenWISP Project.

Geographic add-ons for Django REST Framework. Maintained by the OpenWISP Project.

OpenWISP 982 Jan 06, 2023
r.cfdtools 7 Dec 28, 2022
Specification for storing geospatial vector data (point, line, polygon) in Parquet

GeoParquet About This repository defines how to store geospatial vector data (point, lines, polygons) in Apache Parquet, a popular columnar storage fo

Open Geospatial Consortium 449 Dec 27, 2022
Track International space station with python

NASA-ISS-tracker Track International space station with python Modules import json import turtle import urllib.request import time import webbrowser i

Nikhil Yadav 8 Aug 12, 2021
Client library for interfacing with USGS datasets

USGS API USGS is a python module for interfacing with the US Geological Survey's API. It provides submodules to interact with various endpoints, and c

Amit Kapadia 104 Dec 30, 2022
Simple CLI for Google Earth Engine Uploads

geeup: Simple CLI for Earth Engine Uploads with Selenium Support This tool came of the simple need to handle batch uploads of both image assets to col

Samapriya Roy 79 Nov 26, 2022
PyTorch implementation of ''Background Activation Suppression for Weakly Supervised Object Localization''.

Background Activation Suppression for Weakly Supervised Object Localization PyTorch implementation of ''Background Activation Suppression for Weakly S

34 Dec 27, 2022
Tools for the extraction of OpenStreetMap street network data

OSMnet Tools for the extraction of OpenStreetMap (OSM) street network data. Intended to be used in tandem with Pandana and UrbanAccess libraries to ex

Urban Data Science Toolkit 47 Sep 21, 2022
Blender addons to make the bridge between Blender and geographic data

Blender GIS Blender minimal version : 2.8 Mac users warning : currently the addon does not work on Mac with Blender 2.80 to 2.82. Please do not report

5.9k Jan 02, 2023
Bacon - Band-limited Coordinate Networks for Multiscale Scene Representation

BACON: Band-limited Coordinate Networks for Multiscale Scene Representation Project Page | Video | Paper Official PyTorch implementation of BACON. BAC

Stanford Computational Imaging Lab 144 Dec 29, 2022
Streamlit Component for rendering Folium maps

streamlit-folium This Streamlit Component is a work-in-progress to determine what functionality is desirable for a Folium and Streamlit integration. C

Randy Zwitch 224 Dec 30, 2022