"Error: the action space must be a vector" error is not included in the env_checker
The following assertion which checks if the action-space is a vector or not is not included in the env_checker script but returns an error during the runtime:
if isinstance(ac_space, spaces.Box):
assert len(ac_space.shape) == 1, "Error: the action space must be a vector"
return DiagGaussianProbabilityDistributionType(ac_space.shape[0])
the mentioned is on common/distributions.py and def make_prob_dist_type(): function line 486-488.
Good catch. I would also update assertion to be more informative. It seems to make sure you do not use an Box space with multiple axis. I was bit confused about "must being a vector", and thought it checks if the shape is scalar.
A PR to add this and update env_checker would be welcomed :)
A PR to add this and update env_checker would be welcomed :)
It would be a warning as it is specific to Stable Baselines. But yes, I forgot that one.
@Miffyli @araffin sure! I will add the PR.