Skip to content

Conversation

@hacobe
Copy link
Contributor

@hacobe hacobe commented Jan 6, 2023

Description

This PR patches in the changes from PR #650. It also fixes an error in the dagger configs by replacing "py/object" with "py/type". "py/object" failed the assert in sacred.config.utils.assert_is_valid_key.

Testing

The PR adds a minimal test suite for the benchmarking configs. Running all the configs with the fast configs applied is too slow and requires MuJoCo. Instead, we test that the print_config command works for all the configs.

This commit patches in the changes from PR #650. It also fixes an error in the dagger configs by replacing "py/object" with "py/type". "py/object" failed the assert in sacred.config.utils.assert_is_valid_key. Finally, it adds a minimal test suite for the benchmarking configs. This commit makes progress on testing, but still does not test that all the benchmarking configs work. Running all the configs with the fast configs applied is too slow. Calling sacred's print_config command for all the configs is also too slow.
@hacobe hacobe requested a review from AdamGleave January 6, 2023 20:24
Copy link
Member

@AdamGleave AdamGleave left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding this test! Some minor suggestions.

hacobe added 2 commits January 6, 2023 17:41
Avoid the overhead of subprocess by running the print_config using the experiment's run method. Also, use a path relative to the script for BENCHMARKING_DIR instead of creating a path and then checking if it exists.
Copy link
Member

@AdamGleave AdamGleave left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, 2 small suggestions

@codecov
Copy link

codecov bot commented Jan 7, 2023

Codecov Report

Merging #653 (3115244) into master (d886a8f) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master     #653   +/-   ##
=======================================
  Coverage   97.54%   97.54%           
=======================================
  Files          86       87    +1     
  Lines        8422     8443   +21     
=======================================
+ Hits         8215     8236   +21     
  Misses        207      207           
Impacted Files Coverage Δ
tests/test_benchmarking.py 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@AdamGleave AdamGleave merged commit 9822af1 into master Jan 8, 2023
@AdamGleave AdamGleave deleted the fix-benchmarking-configs branch January 8, 2023 07:03
ernestum added a commit that referenced this pull request Jan 26, 2023
This change just made some error messages go away indicating the missing imitation.algorithms.dagger.ExponentialBetaSchedule but it did not fix the root cause.
@ernestum ernestum mentioned this pull request Jan 26, 2023
3 tasks
ernestum added a commit that referenced this pull request Feb 2, 2023
This change just made some error messages go away indicating the missing imitation.algorithms.dagger.ExponentialBetaSchedule but it did not fix the root cause.
ernestum added a commit that referenced this pull request Feb 3, 2023
This change just made some error messages go away indicating the missing imitation.algorithms.dagger.ExponentialBetaSchedule but it did not fix the root cause.
ernestum added a commit that referenced this pull request Feb 13, 2023
* Undo the changes from #653 to the dagger benchmark config files.

This change just made some error messages go away indicating the missing imitation.algorithms.dagger.ExponentialBetaSchedule but it did not fix the root cause.

* Improve readability and interpretability of benchmarking tests.

* Add exponential beta scheduler for dagger

* Ignore coverage for unknown algorithms.

* Cleanup and extend tests for beta schedules in dagger.

---------

Co-authored-by: taufeeque9 <[email protected]>
AdamGleave pushed a commit that referenced this pull request Oct 10, 2023
* Merge py file changes from benchmark-algs

* Clean parallel script

* Undo the changes from #653 to the dagger benchmark config files.

This change just made some error messages go away indicating the missing imitation.algorithms.dagger.ExponentialBetaSchedule but it did not fix the root cause.

* Improve readability and interpretability of benchmarking tests.

* Add pxponential beta scheduler for dagger

* Ignore coverage for unknown algorithms.

* Cleanup and extend tests for beta schedules in dagger.

* Add optuna to dependencies

* Fix test case

* Clean up the scripts

* Remove reporter(done) since mean_return is reported by the runs

* Add beta_schedule parameter to dagger script

* Update config policy kwargs

* Changes from review

* Fix errors with some configs

* Updates based on review

* Change metric everywhere

* Separate tuning code from parallel.py

* Fix docstring

* Removing resume option as it is getting tricky to correctly implement

* Minor fixes

* Updates from review

* fix lint error

* Add documentation for using the tuning script

* Fix lint error

* Updates from the review

* Fix file name test errors

* Add tune_run_kwargs in parallel script

* Fix test errors

* Fix test

* Fix lint

* Updates from review

* Simplify few lines of code

* Updates from review

* Fix test

* Revert "Fix test"

This reverts commit 8b55134.

* Fix test

* Convert Dict to Mapping in input argument

* Ignore coverage in script configurations.

* Pin huggingface_sb3 version.

* Update to the newest seals environment versions.

* Push gymnasium dependency to 0.29 to ensure mujoco envs work.

* Incorporate review comments

* Fix test errors

* Move benchmarking/ to scripts/ and add named configs for tuned hyperparams

* Bump cache version & remove unnecessary files

* Include tuned hyperparam json files in package data

* Update storage hash

* Update search space of bc

* update benchmark and hyper parameter tuning readme

* Update README.md

* Incorporate reviewer's comments in benchmarking readme

* Update gymnasium version and render mode in eval policy

* Fix error

* Update commands.py hex strings

---------

Co-authored-by: Maximilian Ernestus <[email protected]>
Co-authored-by: ZiyueWang25 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants