Skip to main content

A suite of flexible experiments of a variety of different tasks.

Project description

ExperimentLab

A suite of flexible experiments of a variety of different tasks.

Installation

To create a conda environment for this package use the following commands to do so

conda create -n experiment_lab python=3.11 -y
conda activate experiment_lab

Install the version of pytorch that is compatible with your hardware using the pip or conda command from their website.

To just install the experiment runner framework in one command:

pip install experiment-lab

or

pip install git+https://github.com/rishavb123/ExperimentLab.git

For specific optional dependencies use:

pip install -e "experiment-lab[{name}]"

where {name} can be all, ml, rl, rl-vid, or dev.

To test this installation, try this command (after logging into wandb with wandb login):

run_mc --config-name estimate_pi

which should run a monte carlo experiment to estimate the value of pi. See the experiments project in wandb to view the results of this experiment.

To install this package directly from the github reposity use the following commands:

git clone https://github.com/rishavb123/ExperimentLab.git
cd ExperimentLab
pip install -e .

As a test, try running the following script:

python experiment_lab/experiments/examples/random_waits.py n_runs=20 n_run_method=parallel seed=0

For specific optional dependencies use:

pip install -e ".[{name}]"

where {name} can be all, ml, rl, rl-vid, or dev.

Debugging Tips

Recording Videos on RL experiments

The video recording wrapper from the stable baselines library requires a few dependencies that must be installed before it can be used.

  1. Install moviepy to your python environment. This can be done using through this package via:
pip install "experiment_lab[rl-vid]"

or directly using,

pip install moviepy
  1. Install ffmpeg on your system using the following command (depending on your OS):
  • Ubuntu: sudo apt install ffmpeg
  • Mac: brew instlal ffmpeg
  • Windows: Follow the instructions here. Note that I did not write or review this instructions.
  1. Make sure to set the location of the ffmpeg binary to the `$IMAGEIO_F

Also, it should be noted that there are some issues with using the multiprocessing vector environment with the video recorder. Ensure that the start_method set in the RL config is "spawn" (which is the default if it is left as None) for best results. On MacOS, see this page for potential problems with using "fork".

Project details


Download files

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

Source Distribution

experiment-lab-1.1.0.tar.gz (27.7 kB view details)

Uploaded Source

Built Distribution

experiment_lab-1.1.0-py3-none-any.whl (40.6 kB view details)

Uploaded Python 3

File details

Details for the file experiment-lab-1.1.0.tar.gz.

File metadata

  • Download URL: experiment-lab-1.1.0.tar.gz
  • Upload date:
  • Size: 27.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.8

File hashes

Hashes for experiment-lab-1.1.0.tar.gz
Algorithm Hash digest
SHA256 ffc9f00f8866f12b11d87e4cd7ebeaecffcc9b13e1913957255b02e4cef258fe
MD5 fa8a0b51dd016c30808812adec95fb92
BLAKE2b-256 0ff6436d65ecc4ea2a69c3c46839c4f4928d29f9fa86b991a0ea2afb05a24d86

See more details on using hashes here.

Provenance

File details

Details for the file experiment_lab-1.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for experiment_lab-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b8ea3162eebdfd8f51b802ef29679f43999358bf7d233b9dc15ac8c523ec0d6e
MD5 50543ef282b802c27a03341ee6d08489
BLAKE2b-256 47f6ad13a9412d2fdec22ea5e9ab9ff96815a4e235b1a2598afbb01d2c0642b5

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page