Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/reset before collect in procedural examples, tests and hl experiment #1100

Merged

Conversation

maxhuettenrauch
Copy link
Collaborator

  • I have added the correct label(s) to this Pull Request or linked the relevant issue(s)
  • I have provided a description of the changes in this Pull Request
  • I have added documentation for my changes
  • If applicable, I have added tests to cover my changes.
  • I have reformatted the code using poe format
  • I have checked style and types with poe lint and poe type-check
  • (Optional) I ran tests locally with poe test
    (or a subset of them with poe test-reduced) ,and they pass
  • (Optional) I have tested that documentation builds correctly with poe doc-build

Calling collector.collect currently fails if the collector is not reset before collecting. Not sure if there's also a bug in collector where it says ...It has only an effect if n_episode is not None... for the reset_before_collect kwarg as it also happens when collecting n_step.

@maxhuettenrauch
Copy link
Collaborator Author

@bordeauxred, @MischaPanch fyi

@bordeauxred
Copy link
Contributor

@MischaPanch the examples are not covered by the tests. Does it make to include them in cicd or run them once a day (if at least one commit on this day)
or sth?

@MischaPanch
Copy link
Collaborator

@MischaPanch the examples are not covered by the tests. Does it make to include them in cicd or run them once a day (if at least one commit on this day) or sth?

Once this is merged, we will follow up and write a script which generates the benchmarks that are currently stored in the examples dir and displayed in the docs. Then we can have a manually triggered GH Action that we trigger on each release. Running examples on each PR/daily is too expensive and unnecessary.

Copy link
Collaborator

@MischaPanch MischaPanch 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 spotting!

test/discrete/test_bdq.py Show resolved Hide resolved
examples/atari/atari_dqn.py Show resolved Hide resolved
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 88.22%. Comparing base (8a0629d) to head (9bac3c7).

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1100      +/-   ##
==========================================
+ Coverage   88.21%   88.22%   +0.01%     
==========================================
  Files         100      100              
  Lines        8304     8305       +1     
==========================================
+ Hits         7325     7327       +2     
+ Misses        979      978       -1     
Flag Coverage Δ
unittests 88.22% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@MischaPanch
Copy link
Collaborator

@maxhuettenrauch I thought the sac_with_il seeding problem was fixed now. Is your branch based on the updated master? Or is there some other source of randomness that we're not controlling yet?

@maxhuettenrauch
Copy link
Collaborator Author

@maxhuettenrauch I thought the sac_with_il seeding problem was fixed now. Is your branch based on the updated master? Or is there some other source of randomness that we're not controlling yet?

I doesn't fail on my machine... and it hasn't failed on other PRs, or has it?

@MischaPanch
Copy link
Collaborator

@maxhuettenrauch I thought the sac_with_il seeding problem was fixed now. Is your branch based on the updated master? Or is there some other source of randomness that we're not controlling yet?

I doesn't fail on my machine... and it hasn't failed on other PRs, or has it?

It fails occasionally :D, the worst kind of failing. We'll see with you next pushed commit

@maxhuettenrauch
Copy link
Collaborator Author

@maxhuettenrauch I thought the sac_with_il seeding problem was fixed now. Is your branch based on the updated master? Or is there some other source of randomness that we're not controlling yet?

I doesn't fail on my machine... and it hasn't failed on other PRs, or has it?

It fails occasionally :D, the worst kind of failing. We'll see with you next pushed commit

Weird. It's giving me deterministic results on my machine... but maybe another machine produces different numbers on that seed.

@MischaPanch MischaPanch marked this pull request as ready for review April 5, 2024 09:39
@maxhuettenrauch
Copy link
Collaborator Author

Well, I think this still needs some time. The atari_dqn example is broken in another place due to a recent update on master (at least for me).

@MischaPanch
Copy link
Collaborator

@maxhuettenrauch the L0 notebook fails for some reason, could you check locally pls?

@MischaPanch MischaPanch marked this pull request as draft April 5, 2024 10:00
@maxhuettenrauch
Copy link
Collaborator Author

@maxhuettenrauch the L0 notebook fails for some reason, could you check locally pls?

poe doc-build and poe doc-spellcheck seem to run through on my end. Not sure why it's failing.

@MischaPanch MischaPanch marked this pull request as ready for review April 15, 2024 16:18
@MischaPanch
Copy link
Collaborator

@maxhuettenrauch this is finished, right? I'd merge it

Do you know whether it's related (or even solves) #1111 ?

@maxhuettenrauch
Copy link
Collaborator Author

This should (hopefully) cover all instances of the collect before training starts, yes.

Regarding the other issue, I think #1077 broke it.

@MischaPanch MischaPanch merged commit 60d1ba1 into thu-ml:master Apr 16, 2024
4 checks passed
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.

4 participants