-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: evaluate_policy called multiple times vor vectorized environments #1912
Comments
Hello, the for loop also decompose the info per env: stable-baselines3/stable_baselines3/common/evaluation.py Lines 99 to 106 in 35eccaf
|
How so? Both the globals and locals contain information on every environment in the vectorized environment. How am I supposed to determine for which env the callback is called? |
there is the local variable "i" |
Ah ok sorry then. |
feel free to open a PR that updates the doc ;) |
馃悰 Bug
When calling
with a vecenv, then the callback gets executed for each of the environments separately. However, the locals dict contains the aggregated results. Therefore you have to manually check for which environment the callback was called, or only execute it every
n_envs
time.To Reproduce
Relevant log output / Error message
No response
System Info
Checklist
The text was updated successfully, but these errors were encountered: