Keep track of digital experiments.
Project description
A lightweight python package for recording and analysing configurations and results of coding experiments.
Installation
pip install digital-experiments
Basic Use
- Define your experiment as a pure-python function, and decorate it with
@experiment
:
from digital_experiments import experiment
@experiment
def my_experiment(a, b=2):
return a ** b
- Call the function as normal:
>>> my_experiment(2, 3)
8
>>> my_experiment(4)
16
- Access the results of the experiment:
>>> my_experiment.observations()
[Observation(<id1>, {'a': 2, 'b': 3} → 8}),
Observation(<id2>, {'a': 4, 'b': 2} → 16})]
If you have pandas
installed, you can also access these results as a DataFrame
:
>>> my_experiment.to_dataframe()
id config.a config.b result
0 <id1> 2 3 8
1 <id2> 4 2 16
Documentation
For more information, see the documentation.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
digital-experiments-2.0.1.tar.gz
(13.5 kB
view hashes)
Built Distribution
Close
Hashes for digital-experiments-2.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3920c8283900d8aa90058d970023234a921cdb01d3621ed758107e121d2f7da6 |
|
MD5 | 0fcaeb11775b1dfb91bde8d234ab88ca |
|
BLAKE2b-256 | 0dcfb8c7fb1b82ccfe728d610c766f773bbe181bf004d073d90ba3e04cb1b6a2 |
Close
Hashes for digital_experiments-2.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ff659717a148fa284bf57d453e206e25246081c9da1a8d7202a64c81878ee1b5 |
|
MD5 | 6fbf359dda6f5a1b809160fc1e0e1b8c |
|
BLAKE2b-256 | 196a5afdf0369aaa4085b4e90f52877fe4d0edcee2924b13bef52ce1c3cb653e |