rl4co icon indicating copy to clipboard operation
rl4co copied to clipboard

Update ppo.py

Open bokveizen opened this issue 10 months ago • 1 comments

added "load_from_checkpoint" for PPO

Description

The method "load_from_checkpoint" was missing in PPO.

Motivation and Context

It allows "load_from_checkpoint" of PPOModel for instances now.

  • [ ] I have raised an issue to propose this change (required for new features and bug fixes)

Types of changes

What types of changes does your code introduce? Remove all that do not apply:

  • [ ] Bug fix (non-breaking change which fixes an issue)

Checklist

Go over all the following points, and put an x in all the boxes that apply. If you are unsure about any of these, don't hesitate to ask. We are here to help!

  • [ ] My change requires a change to the documentation.
  • [ ] I have updated the tests accordingly (required for a bug fix or a new feature).
  • [ ] I have updated the documentation accordingly.

bokveizen avatar Apr 26 '24 01:04 bokveizen

Thanks! The previous version was not working? Asking because the load_from_checkpoint is actually overwriting a class method of the LightningModule as seen here, so if it does not cause problems, it could be left

fedebotu avatar Apr 27 '24 06:04 fedebotu