Skip to main content

Facilitates automated and reproducible experimental research

Project description

Every experiment is sacred
Every experiment is great
If an experiment is wasted
God gets quite irate
Current PyPi Version MIT licensed ReadTheDocs Travis-CI Status Coverage Report Code Scrutinizer Quality Wheel Status

Sacred is a tool to help you configure, organize, log and reproduce experiments. It is designed to do all the tedious overhead work that you need to do around your actual experiment in order to:

  • keep track of all the parameters of your experiment
  • easily run your experiment for different settings
  • save configurations for individual runs in a database
  • reproduce your results

In Sacred we achieve this through the following main mechanisms:

  • ConfigScopes A very convenient way of the local variables in a function to define the parameters your experiment uses.
  • Config Injection: You can access all parameters of your configuration from every function. They are automatically injected by name.
  • Command-line interface: You get a powerful command-line interface for each experiment that you can use to change parameters and run different variants.
  • Observers: Sacred provides Observers that log all kinds of information about your experiment, its dependencies, the configuration you used, the machine it is run on, and of course the result. These can be saved to a MongoDB, for easy access later.
  • Automatic seeding helps controlling the randomness in your experiments, such that the results remain reproducible.

Documentation

The documentation is hosted at ReadTheDocs.

Installing

You can directly install it from the Python Package Index with pip:

pip install sacred

Or if you want to do it manually you can checkout the current version from git and install it yourself:

cd sacred
python setup.py install

You might want to also install the numpy and the pymongo packages. They are optional dependencies but they offer some cool features:

pip install numpy, pymongo

Tests

The tests for sacred use the py.test package. You can execute them like this:

python setup.py test

There is also a config file for tox so you can automatically run the tests for various python versions like this:

tox

License

This project is released under the terms of the MIT license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for sacred, version 0.5.2
Filename, size File type Python version Upload date Hashes
Filename, size sacred-0.5.2-py2.py3-none-any.whl (27.4 kB) File type Wheel Python version 2.7 Upload date Hashes View
Filename, size sacred-0.5.2.tar.gz (22.7 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page