I came across this point in a blog:
When setting up your action and observation spaces, stick to Box, Discrete, and Tuple. The MultiDiscrete and MultiBinary don't work (currently) and will cause the run to crash. Instead, wrap Box or Discrete spaces in the Tuple function.
The observation space in my code consists of a dictionary of multidiscrete, multibinary, and discrete values, the action space is also a dictionary of multidiscrete values. Ray version is: (0.8.9).
I have a dummy space in my environment code that invokes only two functions: contain() and sample() from gym.Space to ensure gym.spaces.Dict is derived from gym.Space. However, I keep getting errors related to the shape() function of gym.spaces although it is not invoked in the environment code. And, if I added it to the code, I would get a TypeError from ray/rllib/models/preprocesssors.py.
I am not sure if these errors have anything to do with the way the observation and action spaces are defined (in terms of complexity) as mentioned in the beginning.