Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

Loading the .pth file trained in the Isaac Gym environment #17

Closed
famora2 opened this issue Jun 6, 2022 · 0 comments
Closed

Loading the .pth file trained in the Isaac Gym environment #17

famora2 opened this issue Jun 6, 2022 · 0 comments

Comments

@famora2
Copy link

famora2 commented Jun 6, 2022

Hi,

I really like this feature in skrl which enables simultaneous deploying of agents (https://skrl.readthedocs.io/en/latest/intro/examples.html). However, it would be great if skrl for example can also load the .pth file trained with Isaac Gym Library(https://github.com/NVIDIA-Omniverse/IsaacGymEnvs) for benchmark purposes. Currently, one gets the following errors:


  File "ppo_ant.py", line 135, in <module>
    models_ppo["policy"].load("./ant_best.pth")
  File "/home/user/skrl/skrl/models/torch/base.py", line 302, in load
    self.load_state_dict(torch.load(path))
  File "/home/user/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 1483, in load_state_dict
    self.__class__.__name__, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for Policy:
	Missing key(s) in state_dict: "log_std_parameter", "net.0.weight", "net.0.bias", "net.2.weight", "net.2.bias", "net.4.weight", "net.4.bias", "net.6.weight", "net.6.bias". 
	Unexpected key(s) in state_dict: "running_mean_std", "reward_mean_std", "model", "epoch", "optimizer", "frame", "last_mean_rewards", "env_state". 
Repository owner locked and limited conversation to collaborators Jun 9, 2022
@Toni-SM Toni-SM converted this issue into discussion #19 Jun 9, 2022

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant