Overview#
In order to use pypfilt you will need to define the following things:
A simulation model that describes the behaviour of the system;
See Creating your own model for an example of defining a simulation model.
Prior distribution(s) and parameter bounds;
Specify independent priors for each parameter (see the
LatinHypercube
sampler, which supports all of the scipy.stats distributions and several other distributions); and/orRead correlated priors for multiple parameters from an external file (see Reading prior samples from external data files).
Some observations of the system (either real or simulated from the simulation model);
An observation model that describes how the simulation model and the observations are related;
Use the
Univariate
base class to define observation models in terms of any univariate scipy.stats distribution.
Simulation and particle filter settings, such as:
Particle filter settings, such as the resampling threshold and whether to use post-regularisation;
Select appropriate summary tables to record things of interest; and
A seed for the pseudo-random number generator, so that the results are reproducible.
All of this information is collected into a single TOML file, which pypfilt can then use to generate forecasts.
Note
TOML is a simple, easy to read configuration file format, similar to JSON and YAML.