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

Habitat baselines PPOAgent fails when using pre-trained weights #2097

Open
mikimena01 opened this issue Oct 30, 2024 · 0 comments
Open

Habitat baselines PPOAgent fails when using pre-trained weights #2097

mikimena01 opened this issue Oct 30, 2024 · 0 comments

Comments

@mikimena01
Copy link

Habitat-Lab: master

Habitat-Sim: master

Habitat is under active development, and we advise users to restrict themselves to stable releases of Habitat-Lab and Habitat-Sim. The bug you are about to report may already be fixed in the latest version.

Master branch contains 'bleeding edge' code, but we do appreciate bug reports for it!

When using PPOAgent with default_config and pre-trained weights there is a mismatch between dimensions in the visual encoder output and in the visual_fc input. I have tried to use different weights and configurations. When trying with the training command suggested in the README it works.

File "top_down_test.py", line 345, in example_top_down_map_measure
action = agent.act(observations)
File "/habitat-lab/habitat-baselines/habitat_baselines/agents/ppo_agents.py", line 129, in act
action_data = self.actor_critic.act(
File "/habitat-lab/habitat-baselines/habitat_baselines/rl/ppo/policy.py", line 332, in act
features, rnn_hidden_states, _ = self.net(
File "/.conda/envs/habitat/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/habitat-lab/habitat-baselines/habitat_baselines/rl/ddppo/policy/resnet_policy.py", line 647, in forward
visual_feats = self.visual_fc(visual_feats)
File "/.conda/envs/habitat/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/.conda/envs/habitat/lib/python3.9/site-packages/torch/nn/modules/container.py", line 217, in forward
input = module(input)
File "/.conda/envs/habitat/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/.conda/envs/habitat/lib/python3.9/site-packages/torch/nn/modules/linear.py", line 114, in forward
return F.linear(input, self.weight, self.bias)
RuntimeError: mat1 and mat2 shapes cannot be multiplied (1x10240 and 2048x512)

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

No branches or pull requests

1 participant