A complete ecosystem for wildlife monitoring and conservation using aerial imagery.
WildDetect is an integrated monorepo containing three specialized packages for the entire wildlife detection workflowβfrom data management to model training and deployment.
ποΈ WilData - Data Management
Unified data pipeline for dataset management and preparation.
- Multi-format import/export (COCO, YOLO, Label Studio)
- Data transformations (tiling, augmentation, clipping)
- ROI dataset creation for classification
- DVC integration for version control
- REST API for programmatic access
π WildTrain - Model Training
Modular training framework for detection and classification models.
- YOLO and MMDetection support
- PyTorch Lightning for classification
- MLflow experiment tracking
- Hyperparameter optimization (Optuna)
- Model registration and versioning
π WildDetect - Detection & Analysis
Production-ready detection system with census capabilities.
- Multi-threaded detection pipelines
- Large raster image support (GeoTIFF)
- Census campaign orchestration
- Geographic analysis and visualization
- FiftyOne integration
- Comprehensive reporting (JSON, CSV, PDF)
# Clone the repository
git clone https://github.com/fadelmamar/wildetect.git
cd wildetect
# Create virtual environment
uv venv --python 3.10
.venv\Scripts\activate # Windows
# Install all packages
cd wildata && uv pip install -e . && cd ..
cd wildtrain && uv pip install -e . && cd ..
uv pip install -e .# Run detection
wildetect detect /path/to/images --model model.pt --output results/
# Run census campaign
wildetect census campaign_2024 /path/to/images --model model.pt --output campaign_results/Complete documentation is available at: WildDetect Documentation
- Multi-species detection optimized for aerial imagery
- Batch processing of large datasets
- Raster detection for GeoTIFF files
- Multi-threaded pipelines for performance
- Import from COCO, YOLO, Label Studio
- Data transformations (tiling, augmentation)
- ROI extraction for classification
- DVC integration for versioning
- YOLO and MMDetection frameworks
- PyTorch Lightning for classification
- MLflow experiment tracking
- Hyperparameter optimization
- GPS metadata extraction and management
- Flight path analysis and coverage maps
- Population density calculations
- Interactive visualizations with FiftyOne
- Full census campaign orchestration
- Species counting and statistics
- Distribution analysis
- Comprehensive PDF reports
wildetect detect # Run wildlife detection
wildetect census # Census campaign
wildetect analyze # Analyze results
wildetect visualize # Create visualizations
wildetect fiftyone # Launch FiftyOne viewer
wildetect ui # Launch web interfacewildata import-dataset # Import dataset
wildata dataset list # List datasets
wildata dataset export # Export dataset
wildata create-roi # Create ROI dataset
wildata visualize-dataset # Visualize datawildtrain train classifier # Train classification model
wildtrain train detector # Train detection model
wildtrain eval classifier # Evaluate model
wildtrain register # Register to MLflowFor all options:
wildetect --help
wildata --help
wildtrain --helpWildDetect provides a powerful and flexible command-line interface (CLI) built with Typer, making it easy to run wildlife detection, census campaigns, analysis, visualization, and moreβall from your terminal.
After installing WildDetect, simply run:
wildetect [COMMAND] [OPTIONS]You can always see all available commands and options with:
wildetect --help-
detect
Run wildlife detection on images or directories of images.wildetect detect /path/to/images --model model.pt --output results/
Options include model type, confidence threshold, device (CPU/GPU), batch size, tiling, and more.
-
census
Orchestrate a full wildlife census campaign, including detection, statistics, and reporting.wildetect census campaign_2024 /path/to/images --model model.pt --output campaign_results/
Supports campaign metadata, pilot info, target species, and advanced analysis.
-
analyze
Analyze detection results for statistics and insights.wildetect analyze results.json --output analysis/
-
visualize
Create interactive geographic maps and visualizations from detection results.wildetect visualize results.json --output maps/
-
info
Display system and environment information, including dependencies and hardware support.wildetect info
-
ui
Launch the WildDetect web interface (Streamlit-based) for interactive exploration.wildetect ui
-
fiftyone
Manage FiftyOne datasets: launch the app, get info, or export data.wildetect fiftyone --action launch wildetect fiftyone --action info --dataset my_dataset wildetect fiftyone --action export --format coco --output export_dir/ -
clear-results
Delete all detection results in a specified directory (with confirmation).
- Rich Output: Uses rich for beautiful tables, progress bars, and colored logs.
- Flexible Input: Accepts both individual image files and directories.
- Advanced Options: Fine-tune detection, tiling, device selection, and more.
- Batch Processing: Efficiently processes large datasets.
- Integration: Seamless export to FiftyOne, JSON, and CSV formats.
- Help for Every Command: Use
wildetect [COMMAND] --helpfor detailed options.
wildetect/ # Monorepo root
βββ wildata/ # Data management package
β βββ src/wildata/
β βββ configs/
β βββ scripts/
β βββ tests/
βββ wildtrain/ # Training framework package
β βββ src/wildtrain/
β βββ configs/
β βββ scripts/
β βββ tests/
βββ src/wildetect/ # Detection package
β βββ core/
β βββ cli/
β βββ api/
β βββ ui/
βββ config/ # WildDetect configurations
βββ scripts/ # Batch scripts
βββ docs/ # Documentation
βββ tests/ # Tests
# 1. Run detection
wildetect detect images/ --model model.pt --output results/
# 2. View in FiftyOne
wildetect fiftyone --action launch
# 3. Analyze results
wildetect analyze results/detections.json# 1. Import dataset
cd wildata
wildata import-dataset annotations.json --format coco --name dataset
# 2. Apply transformations (tiling)
# (configured in import config)
# 3. Export for training
wildata dataset export dataset --format yolo# 1. Train model
cd wildtrain
wildtrain train detector -c configs/detection/yolo.yaml
# 2. Evaluate
wildtrain eval detector -c configs/detection/yolo_eval.yaml
# 3. Register to MLflow
wildtrain register detector config/registration.yaml# 1. Configure census (edit config/census.yaml)
# 2. Run census
wildetect census campaign_2024 images/ -c config/census.yaml
# 3. View report
# Open census_results/report.pdf- Python 3.9+ - Primary language
- PyTorch - Deep learning framework
- YOLO / MMDetection - Object detection
- PyTorch Lightning - Training framework
- MLflow - Experiment tracking
- FiftyOne - Dataset visualization
- FastAPI - REST API
- Streamlit - Web interfaces
- DVC - Data versioning
- Hydra - Configuration management
- Typer - CLI interfaces
Contributions are welcome! This is an open-source project for the conservation community.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Please ensure:
- Code follows project style (use
ruff) - Tests pass (
uv run pytest tests/ -v) - Documentation is updated
- Commit messages are descriptive
MIT License - see LICENSE for details.
- Documentation: docs/index.md
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Conservation organizations using this toolkit
- Open-source community
- YOLO and MMDetection teams
- PyTorch and Lightning teams
Ready to get started? Head to the Installation Guide or Quick Start!
