Skip to main content

Identify optically shallow and deep waters in satellite imagery

Project description

Optically-Shallow-Deep

This python tool delineates optically shallow and deep waters in Sentinel-2 imagery. The tool uses a deep neural network that was trained on a diverse set of global images.

Supported input includes L1C SAFE files and ACOLITE-processed L2R netCDF files. The output geotiff contains probabilities of water pixels being optically shallow and deep.

Output is a 3-band geotiff:

  • B1: Binary prediction (OSW/ODW)
  • B2: Prediction probability of OSW (100 means most likely OSW, 0 means most likely ODW)
  • B3: pixels that are masked out

Originally coded by by Galen Richardson and Anders Knudby, modified and uploaded by Yulun Wu

Installation

1 - Create a conda environment and activate it:

conda create --name opticallyshallowdeep
conda activate opticallyshallowdeep

2 - Install tensorflow

For mac OS:

conda install -c apple tensorflow-deps
python -m pip install tensorflow-macos

(Optional) To utilize GPUs on mac OS:

python -m pip install tensorflow-metal

For windows:

python3 -m pip install tensorflow

More on installing tensorflow: https://www.tensorflow.org/install

3 - Install other dependencies:

conda install -c conda-forge geopandas rasterio tifffile netCDF4 pyproj

4 - Install opticallyshallowdeep:

python3 -m pip install opticallyshallowdeep

Quick Start

import opticallyshallowdeep as osd
file_in = 'test_folder_in/S2.SAFE'
folder_out = 'folder/test_folder_out'
osd.run(file_in, file_out)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

opticallyshallowdeep-1.0.0.tar.gz (255.7 kB view hashes)

Uploaded Source

Built Distribution

opticallyshallowdeep-1.0.0-py3-none-any.whl (256.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page