Part of the VIEWS Platform ecosystem for large-scale conflict forecasting.
- Overview
- Role in the VIEWS Pipeline
- Features
- Installation
- Usage
- Configuration & Stability
- Architecture
- Project Structure
- Contributing
- License
- Acknowledgements
HydraNet is an advanced machine learning model designed for spatiotemporal forecasting of violent conflict at high granularity. It predicts three types of violenceβstate-based, non-state-based, and one-sidedβby solving regression and classification tasks concurrently.
The model provides:
- Probabilistic Outputs: Enables uncertainty quantification through posterior distributions.
- Temporospatial Learning: Leverages convolutional layers for spatial dependencies and LSTMs for temporal patterns.
- Multi-Tasking: Simultaneously predicts probabilities and magnitudes of conflict.
HydraNet is FAIR-compliant (Findable, Accessible, Interoperable, Reusable), ensuring transparency and ease of use for researchers and policymakers.
HydraNet is a core component of the Violence & Impacts Early Warning System (VIEWS) pipeline, working alongside other repositories:
- views-pipeline-core: Manages data ingestion, preprocessing, and pipeline orchestration.
- views-models: Provides interfaces to train, test, and deploy HydraNet.
- views-evaluation: Evaluates model predictions and performs calibration tasks.
- docs: Organization/pipeline level documentation.
HydraNet fits into the VIEWS pipeline as follows:
- Data Input: Preprocessed PRIO grid-cell-level conflict data is retrieved from views-pipeline-core.
- Model Execution: HydraNet generates probabilistic forecasts for multiple violence types across a 36-month horizon.
- Evaluation and Calibration: Outputs are passed to views-evaluation for ensembling and alignment with other models.
- Multi-Task Learning: Simultaneous prediction of probabilities and magnitudes for three conflict types.
- Uncertainty Quantification: Generates posterior distributions for robust decision-making.
- Hybrid Architecture: Combines CNNs for spatial dependencies, LSTMs for temporal patterns, and U-net for precision.
- Minimal Manual Engineering: Relies solely on past conflict history, simplifying input requirements.
- Scalable Design: Adaptable for new features and forecasting tasks.
- Python >= 3.8
- GPU support recommended (e.g., NVIDIA CUDA).
See the organization/pipeline level docs
See the organization/pipeline level docs
HydraNet seamlessly integrates into the broader VIEWS pipeline. After training and prediction, the outputs can be passed into the views-evaluation repository for further analysis and calibration.
HydraNet uses a Strict Handshake protocol to ensure production predictability. All hyperparameters are validated against a Pydantic schema (HydraNetConfig) at the start of every task.
- Fail-Fast: If a required field is missing or a value is invalid (e.g., a typo in
transform), the program will halt immediately with a detailed error report. - Safe-Mode: The system uses internal state protection to ensure that critical paths (like model saving and data loading) are robust against partial initializations or mocked environments.
HydraNet employs a probabilistic recurrent U-net architecture optimized for spatiotemporal conflict forecasting.
- CNNs (Convolutional Neural Networks): Capture intricate spatial patterns in grid-cell data.
- LSTMs (Long Short-Term Memory networks): Model temporal dependencies and trends.
- Dropout Layers: Enable Monte Carlo sampling to quantify model uncertainty.
- Multi-Decoder Design: Outputs six distinct forecasts (probabilities and magnitudes for three violence types).
- Input: Historical conflict fatalities categorized as state-based, non-state, and one-sided.
- Data Processing: Converts historical data into z-stacks of monthly grids with three channels (one for each violence type).
- Prediction: Generates six outputs: probabilities and magnitudes for each type of violence.
For a detailed explanation of the architecture, refer to the HydraNet Paper.
views_hydranet/
βββ README.md # Documentation
βββ tests # Unit and integration tests
βββ views_hydranet # Main source code
β βββ architecture # Model definitions (CNN + LSTM + U-net)
β βββ evaluate # Evaluation scripts
β βββ forecast # Forecasting utilities
β βββ manager # Workflow management
β βββ train # Training logic
β βββ utils # Helper functions (logging, metrics, etc.)
β βββ __init__.py # Package initialization
βββ .gitignore # Git ignore rules
βββ pyproject.toml # Poetry project file
βββ poetry.lock # Dependency lock file
We welcome contributions to HydraNet! Please follow the contribution guidelines outlined in the organization-level documentation.
...
HydraNet builds upon:
- UCDP Georeferenced Event Dataset (GED) for conflict data.
- PRIO Grid for spatial resolution.
- Concepts from Hegre et al. (2019), Hegre et al. (2021), and Vesco et al. (2022).
- Funding from the European Research Council and the Danish Research Council.
Special thanks to the VIEWS MD&D Team for their collaboration, guidance, and efforts.

