This simple model application runs a simple SEIRS epidemiology model and registers the metadata of the model run on the FAIR Data Pipeline, using the cppDataPipeline API.
The simpleModel executable can be compiled using cmake.
The only external dependancies not included is: gnuplot, gnuplot is required to run the executable and should be installed and the gnuplot executable available in the system path.
gnuplot can be installed using the following commands:
gnuplot can be installed on windows using chocolatey:
choco install gnuplot
gnuplot can be installed on linux using apt:
sudo apt-get install gnuplot
gnuplot can be installed on mac using homebrew:
brew install gnuplot
Compile the executable by running:
$ cmake -Bbuild
$ cmake --build build
Important For multi-config compilers such as Visual Studio xcode or ninja the config type needs to be set to Release
otherwise the API will not build for example:
$ cmake -Bbuild
$ cmake --build build --config=Release
The executable is located in the build/bin[/release]
directory
The executable is designed to be run in conjuction with the fair cli:
(From a virtual environment within the repo directory)
The FAIR commandline interface is available to install using pip:
pip install fair-cli
Once installed the model can be run using the following:
fair init
fair pull data/seirs_config.yaml
fair run data/seirs_config.yaml
fair init
fair pull data/seirs_config_windows.yaml
fair run data/seirs_config_windows.yaml
The executable can run standalone and run the SEIRS model taking in a csv with initial parameters:
build/bin/cppSimpleModel data/static_params_SEIRS.csv
build/bin/release/cppSimpleModel.exe data\static_params_SEIRS.csv