-
Notifications
You must be signed in to change notification settings - Fork 18
Add single bid DRL strategy #576
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
Conversation
- make the DRL bidding strategies initialization more flexible with the ability to change default obs and act dimensions - refactor rl strategies tests to use parametrization
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a new single-bid DRL strategy, refactors existing DRL strategy tests to use parametrization, and updates the reinforcement learning algorithms to support dynamic agent counts and weight transfers.
- Introduces RLStrategySingleBid with a simplified bidding structure
- Refactors fixtures and tests in test_rl_strategies.py and adds extensive tests in test_matd3.py
- Updates learning strategy and algorithm modules for more flexible policy initialization and weight transfer
Reviewed Changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
File | Description |
---|---|
tests/test_rl_strategies.py | Refactored tests to use parametrization and renamed fixtures for clarity |
tests/test_matd3.py | Added extensive tests for saving, loading, and weight transfers in TD3 |
assume/strategies/learning_strategies.py | Introduced BaseLearningStrategy and RLStrategySingleBid, along with minor refactoring in RLStrategy |
assume/scenario/loader_csv.py | Updated prompt messages and warning texts regarding overwriting policies |
assume/reinforcement_learning/learning_utils.py | Added utility functions for hidden size extraction, agent inference, and weight transfer |
assume/reinforcement_learning/learning_role.py | Modified exploration mode logic with a new loaded-only parameter |
assume/reinforcement_learning/algorithms/matd3.py | Enhanced critic parameter loading to support agent count differences and weight transfers |
Files not reviewed (1)
- docs/source/release_notes.rst: Language not supported
Comments suppressed due to low confidence (1)
assume/strategies/learning_strategies.py:195
- The variable name 'obd_dim' appears ambiguous and is likely a typo. Consider renaming it to 'obs_dim' for clarity and consistency with the rest of the code.
obd_dim = kwargs.pop("obs_dim", 38)
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #576 +/- ##
==========================================
+ Coverage 79.51% 79.59% +0.07%
==========================================
Files 52 52
Lines 7342 7370 +28
==========================================
+ Hits 5838 5866 +28
Misses 1504 1504
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
@kim-mskw a review here would be really nice :-) |
…o add-single-bid-rl-strategy
Pull Request
Description
Adds a single-bid DRL strategy. To be merged after #574.
Proposed Changes
Testing
Added a new test for the bidding strategy.
Checklist
Please check all applicable items:
doc
folder updates)pyproject.toml
doc/release_notes.rst
of the upcoming release is included