This is a little fix for Sinergym's action wrappers in order to adapt it to the SB3 algorithms.
Motivation and Context
[ ] I have raised an issue to propose this change (required for new features and bug fixes)
Why is this change required? What problem does it solve? Please, reference issue or issues opened previously.
The current ActionWrappers work perfectly with Gymnasium. However, there was a bug with SB3 algorithms. The action Wrappers update the action before to send it to the next layer. SB3 copy the last layer action value instead the action used in the network input (which is translated in errors). To avoid this, the action parsers copy do a copy of the original action before to start to manipulate it.
Types of changes
[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
Description
This is a little fix for Sinergym's action wrappers in order to adapt it to the SB3 algorithms.
Motivation and Context
Why is this change required? What problem does it solve? Please, reference issue or issues opened previously.
The current ActionWrappers work perfectly with Gymnasium. However, there was a bug with SB3 algorithms. The action Wrappers update the action before to send it to the next layer. SB3 copy the last layer action value instead the action used in the network input (which is translated in errors). To avoid this, the action parsers copy do a copy of the original action before to start to manipulate it.
Types of changes
Checklist:
autopep8
second level aggressive.isort
.cd docs && make spelling && make html
pass (required if documentation has been updated.)pytest tests/ -vv
pass. (required).pytype -d import-error sinergym/
pass. (required)Changelog: