Important
This software is Sandbox and subject to ECMWF's guidelines on Software Maturity.
Forecast-In-A-Box is a prototype system to deliver ECMWF products on demand as generated by Anemoi models. It integrates pproc, anemoi, earthkit and other components of the ECMWF stack.
# first activate your venv or something
mkdir -p ~/.fiab
uv pip install -e backend[test]
uv pip install --prerelease=allow --upgrade multiolib==2.6.1.dev20250613 # this is a known working version -- once we get past dev, this will disappear
pytest backend # just to ensure all is good
Note the above will likely change over time -- you may want to instead run ./backend/fiab.sh
, perhaps with explicit FIAB_ROOT
(as it defaults to "~/.fiab"
). Note in particular that this command creates a venv in $FIAB_ROOT/venv
unless one exists already.
Installation:
# backend
uv venv --seed ./
uv pip install ./backend[all]
# frontend
cd frontend
npm install yarn
Running the server:
cd frontend
yarn dev
cd backend
uvicorn forecastbox.entrypoint:app --reload --log-level info
python -m cascade.gateway tcp://localhost:8067
bash ./backend/fiab.sh # used both as installer script *and* launcher
To use the prebuilt containers use the following docker-compose file, otherwise the default in the repo will build.
name: FIAB
services:
frontend:
container_name: fiab-frontend
image: ghcr.io/ecmwf/forecast-in-a-box/frontend:latest
ports:
- "3000:3000"
networks:
- fiab-network
backend:
container_name: fiab-backend
image: ghcr.io/ecmwf/forecast-in-a-box/backend:latest
volumes:
- data:/app/data_dir
- ~/.ssh:/root/.ssh:ro
- ~/.ecmwfapirc:/root/.ecmwfapirc:ro
ports:
- "8000:8000"
depends_on:
- db
environment:
API__API_URL: "http://backend:8000"
API__DATA_PATH: "/app/data_dir"
API__MODEL_REPOSITORY: "https://sites.ecmwf.int/repository/fiab"
CASCADE__CASCADE_URL: "tcp://cascade:8067"
DB__MONGODB_URI: "mongodb://db:27017"
DB__MONGODB_DATABASE: "fiab"
ECMWF_API_URL: "https://api.ecmwf.int/v1"
ECMWF_API_KEY: ${ECMWF_API_KEY}
ECMWF_API_EMAIL: ${ECMWF_API_EMAIL}
FIAB_INSTALL_TYPE: all
networks:
- fiab-network
cascade:
container_name: fiab-cascade
image: ghcr.io/ecmwf/forecast-in-a-box/cascade:latest
entrypoint: "python -m cascade.gateway tcp://0.0.0.0:8067"
networks:
- fiab-network
ports:
- "48165:48165"
shm_size: '5gb'
volumes:
- data:/app/data_dir
- ~/.ssh:/root/.ssh:ro
- ~/.ecmwfapirc:/root/.ecmwfapirc:ro
# Change depending on the GPU Resources available
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
db:
container_name: fiab-db
image: mongo:8.0
networks:
- fiab-network
networks:
fiab-network:
driver: bridge
volumes:
data:
Set the ecmwf-api-client keys from ECMWF API Key Management as env vars.
Then:
docker-compose up --build