Skip to content

POSEIDON (Photogrammetric Observation and Segmentation for Estimation of Inundation Depth ON-demand) is a Python-based workflow for flood-level extraction from imagery. It uses image segmentation and georectification techniques to detect water surfaces and estimate flood depths over real-world terrain.

License

Notifications You must be signed in to change notification settings

rtmccune/poseidon

Repository files navigation

POSEIDON banner

POSEIDON

Photogrammetric Observation and Segmentation for Estimation of Inundation Depth ON-demand


POSEIDON is a Python-based scientific tool for automated flood-level extraction from imagery.
It integrates image segmentation and georectification to detect water surfaces and estimate flood depths across real-world terrain.

Setup

Clone the Repository

git clone --recurse-submodules https://github.com/rtmccune/poseidon.git

Environment

To create a conda environment for this workflow navigate to your local copy of the 'poseidon' repository and run the following command:

conda env create --file poseidon_deploy/environment.yml

To create a conda environment on a linux-64 based system (such as an HPC system) for this workflow navigate to the 'poseidon' repository and run the following command:

conda env create --prefix /path/to/conda/env --file poseidon_deploy/poseidon-linux-64-lock.yml

C++ Executables

These executables rely on the opencv library for processing. First, ensure that you have opencv installed on your system.

To install opencv: On Ubuntu/Debian-based systems run:

sudo apt install libopencv-dev

On Fedora/RHEL-based systems run:

sudo dnf install opencv-devel

On macOS:

brew install opencv

After the working 'poseidon' environment and OpenCV have been installed on your system, compile the executables using cmake:

  1. Activate poseidon conda environment.
conda activate poseidon
  1. Create a build directory.
cd poseidon_utils/src
mkdir build
cd build
  1. Configure the build for your system.
cmake ..
  1. Build the exectuables.
make

The compiled executables will now exist in the 'bin' directory for use. You can test that these compiled executables are working by running the test_compiled_funcs.sh script from the docs/tests directory. To run these tests from the 'bin' directory simply:

../../tests/test_compiled_funcs.sh

Segmentation Gym Container

From the repository root directory run:

apptainer pull poseidon_deploy/segmentation/container/seg_gym.sif oras://ghcr.io/rtmccune/segmentation-gym-tf:latest

Python Tests

To test the posedion library, run the following command from the 'poseidon' directory.

python -m pytest -v tests/

About

POSEIDON (Photogrammetric Observation and Segmentation for Estimation of Inundation Depth ON-demand) is a Python-based workflow for flood-level extraction from imagery. It uses image segmentation and georectification techniques to detect water surfaces and estimate flood depths over real-world terrain.

Topics

Resources

License

Stars

Watchers

Forks