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

Hi, I have this error in running! #13

Closed
BCWang93 opened this issue Apr 17, 2019 · 12 comments
Closed

Hi, I have this error in running! #13

BCWang93 opened this issue Apr 17, 2019 · 12 comments

Comments

@BCWang93
Copy link

The error is like this:

'Process Process-3:
Traceback (most recent call last):
File "/home/a/anaconda3/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap
self.run()
File "/home/a/anaconda3/lib/python3.6/multiprocessing/process.py", line 93, in run
self._target(*self._args, **self._kwargs)
File "/home/a/COMA/pymarl/src/runners/parallel_runner.py", line 221, in env_worker
reward, terminated, env_info = env.step(actions)
File "/home/a/anaconda3/lib/python3.6/site-packages/smac/env/starcraft2/starcraft2.py", line 373, in step
agent_action = self.get_agent_action(a_id, action)
File "/home/a/anaconda3/lib/python3.6/site-packages/smac/env/starcraft2/starcraft2.py", line 439, in get_agent_action
"Agent {} cannot perform action {}".format(a_id, action)
AssertionError: Agent 0 cannot perform action 0
'
Can you help me to solve this?Thanks!

@PaLeroy
Copy link

PaLeroy commented Apr 17, 2019

Hey,
Just got the same error on several runs using COMA.
Were you using COMA too?
However, it never occurred using QMIX algorithms.

@BCWang93
Copy link
Author

Hey,
Just got the same error on several runs using COMA.
Were you using COMA too?
However, it never occurred using QMIX algorithms.

yes,I also use the coma.Did you know how to solve this problem?

@BCWang93
Copy link
Author

Hey,
Just got the same error on several runs using COMA.
Were you using COMA too?
However, it never occurred using QMIX algorithms.

yes, I also using COMA,Do you know how to solve this problem?

@PaLeroy
Copy link

PaLeroy commented Apr 18, 2019

I have not investigated yet.
I got this bug "randomly" after 242030, 10046672 and 4677522 transitions.
It seems to be always caused by the action 0 (the no-op action when a unit is dead).
But the exception occurs simply if the selected action is not an available one, not because the unit is not dead...

@tabzraz
Copy link
Collaborator

tabzraz commented May 3, 2019

Sorry for the late reply. It's unlikely I'll be able to take a look at this issue in the next couple of weeks.

Are you using pytorch version >1?

If the problem only occurs with COMA, then the code for the parallel_runner is unlikely to be the problem.

Any unavailable actions should not be chosen by the action selector, but it would be worth checking that is indeed true.

@BCWang93
Copy link
Author

BCWang93 commented May 5, 2019

Sorry for the late reply. It's unlikely I'll be able to take a look at this issue in the next couple of weeks.

Are you using pytorch version >1?

If the problem only occurs with COMA, then the code for the parallel_runner is unlikely to be the problem.

Any unavailable actions should not be chosen by the action selector, but it would be worth checking that is indeed true.

Hi,thanks for your reply!I am use the pytorch version is >1.I am not test other algorithm recently!But somebody test the qmix algorithm is running normal!

@BCWang93
Copy link
Author

BCWang93 commented May 7, 2019

Sorry for the late reply. It's unlikely I'll be able to take a look at this issue in the next couple of weeks.
Are you using pytorch version >1?
If the problem only occurs with COMA, then the code for the parallel_runner is unlikely to be the problem.
Any unavailable actions should not be chosen by the action selector, but it would be worth checking that is indeed true.

so,can you solve this problem in recent weeks?Thank you!

@BCWang93
Copy link
Author

so,can you solve this problem in recent weeks?Thank you! @samvelyan

@jyericlin
Copy link

Encountered the same issue when running QMIX as well. It occurs when running the following command:
python3 src/main.py --config=qmix_smac --env-config=sc2 with env_args.map_name=2s3z

Tested it in two machines, but both have the same issue. I am using PyTorch 0.4.1. I would appreciate if you could provide pointers on how to fix this issue.

@tabzraz
Copy link
Collaborator

tabzraz commented Oct 10, 2019

I'll take another look at this issue soon.
When I've been running experiments using the parallel_runner I haven't come across this.

@tabzraz
Copy link
Collaborator

tabzraz commented Dec 6, 2019

I haven't been able to reproduce this to debug it.

@tabzraz tabzraz closed this as completed Dec 6, 2019
@GoingMyWay
Copy link

GoingMyWay commented Sep 10, 2020

Same issue with QMIX. Rarely happens but happened today.

AssertionError: Agent 3 cannot perform action 0

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

5 participants