Tools for processing, organizing, and visualizing NES-LTER Stingray / ISIIS sensor and imaging data.
This package includes sensor-processing utilities, CTD/profile handling, image-link helpers, CSV I/O tools, statistical helpers, and a Dash dashboard for interactive exploration of Stingray cruise data.
git clone https://github.com/anhph95/stingraytools.git
cd StingrayToolssudo apt update
sudo apt install python3-venv -y
python3 -m venv venv
source venv/bin/activate
pip install -e .wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
bash Miniconda3-latest-Linux-x86_64.sh
source ~/.bashrc
conda env create -f environment.yml
conda activate stingray
pip install -e .python -m stingray sensors merge \
--cruise EN706 \
--start YYYY-MM-DD \
--end YYYY-MM-DD \
--root sensor_data \
--out-dir dash_data/data/stingray_timebinnedCommon options:
--cruise CRUISE
Cruise ID, e.g. EN706.
--start START
Cruise start date in YYYY-MM-DD format.
--end END
Cruise end date in YYYY-MM-DD format.
--root ROOT
Path to the raw sensor-data directory. Default: sensor_data.
--cal-year CAL_YEAR
Sensor calibration year. Default: 2021.
--time-bin-seconds TIME_BIN_SECONDS
Time-bin size in seconds. Default: 5.
--out-dir OUT_DIR
Output directory for dashboard-ready CSV files.
--media-list-dirs MEDIA_LIST_DIRS ...
Media-list directories for ISIIS image links.
--overwrite-index
Rebuild cached sensor-file indexes.
--log-level {DEBUG,INFO,WARNING,ERROR}
Logging level. Default: INFO.
The package also includes modules for sensor-specific processing and image/media metadata handling:
stingray.sensors.ctd
stingray.sensors.fluorometer
stingray.sensors.par
stingray.sensors.suna
stingray.sensors.merge
stingray.images.frame_timestamp
stingray.images.get_tator_link
stingray.images.abundance
stingray.images.generate_training
Use the relevant module directly or import functions from Python scripts and notebooks as needed.
The dashboard reads data from the configured dash_data/ directory. Expected local structure:
dash_data/
├── data/
│ └── <dataset_name>/
│ └── *.csv
└── misc/
├── NESLTER_station_list.csv
└── NESLTER_transect_bathymetry.csv
python -m stingray dashboard run --host 0.0.0.0 --port 8050Then open:
http://localhost:8050
Dashboard-ready data from dash_data/data can be copied to:
\\vast.whoi.edu\proj\nes-lter\stingray_dashboard\dash_data\data
The dashboard can then be accessed at:
https://stingraydash.whoi.edu/
The dashboard can also be run with Docker Compose.
docker compose up --buildThis builds the image, mounts dash_data/, and serves the app at:
http://localhost:8050
docker compose downdocker compose up -dStop it with:
docker compose downIf dash_data/ is mounted as a bind volume, updating CSV files does not require rebuilding the Docker image.
Rebuild after modifying source code, dashboard code, assets, dependencies, or Docker configuration:
docker compose up --buildInstall in editable mode during development:
pip install -e .Useful checks:
python -m stingray.process --help
python -m stingray.dashboard.app --helpThis project is licensed under the MIT License. See the LICENSE file for details.
- Anh Pham
- Sidney Batchelder
- Heidi Sosik
GitHub Repository: https://github.com/anhph95/StingrayTools