-
Notifications
You must be signed in to change notification settings - Fork 11
Workflow
Building and deploying flusight is a three step process:
- Parse forecasts data in a form ingestible by flusight
- Build visualizer using
yarn run build
- Host the files generated in
./dist
This document describes the the working of the first step for collecting data from CDC FluSight style csvs.
This step creates the following json data files in ./src/assets/data/
which
are then used by the build step:
- Historical data file (
history.json
) containing true time series data for a few past seasons. - Metadata file (
metadata.json
) containing data about US states, HHS regions etc. - Score files (
scores-<season-id|latest>
) containing performance scores of the predictions. - Main season files (
season-<season-id|latest>
) containing the predictions and other data for display in the main time chart view. - Distribution files
(
distributions/season-<season-id|latest>-<region-id>.json
) containing distributions information for the predictions to be displayed in the distribution view.
By default, the repository provides scripts to generate these data files using
csv files in the CDC FluSight Challenge's format. For using this structure the
csv files should be arranged in the directory ./data
as season* → model →
epidemic week with each model directory having a meta.yaml
file with
details about the submission. The meta.yaml
should contain the following
fields.
name: 'Name of the model'
description: 'Short description'
url: 'Team url'
The model id
used for legend and tooltip display is taken from the directory
name itself. A sample metadata file ./data/2015-2016/sent/meta.yaml
(sent
is
its display id) could be like this:
title: 'Sentinel Model'
description: 'Baseline model from Cybertron'
url: 'http://tfwiki.net/wiki/Cybertron_(planet)'
Here is a sample structure for ./data
:
.
|-- 2014-2015
| |-- model-a
| | |-- 201441.csv
| | |-- 201444.csv
| | |-- 201501.csv
| | `-- meta.yaml
| |-- model-b
| | |-- 201440.csv
| | |-- 201441.csv
| | `-- meta.yaml
| `-- model-c
| |-- 201440.csv
| |-- 201441.csv
| `-- meta.yaml
`-- 2015-2016
|-- model-a
| |-- 201501.csv
| |-- 201502.csv
| `-- meta.yaml
|-- model-b
| |-- 201501.csv
| |-- 201502.csv
| `-- meta.yaml
`-- model-c
|-- 201501.csv
|-- 201502.csv
`-- meta.yaml
Running yarn run parse
will then perform the necessary transformations after
collecting actual flu data using the
delphi-epidata API to make the
final jsons.