Farama-Foundation / Minigrid

Simple and easily configurable grid world environments for reinforcement learning
https://minigrid.farama.org/
Other
2.13k stars 610 forks source link

[Question] How to interpret / understand the observation space #366

Closed VineetTambe closed 1 year ago

VineetTambe commented 1 year ago

Question

I was going through the documentation. But couldn't exactly pin down the following information:

  1. what the OBJECT_IDX and COLOR_IDX paramters received in the state mean? From the names I understand that they are mapped to some object and color but what is that mapping? This is the doc page that I was refering to. It does have a link to where this mapping should be (minigrid.py) but it redirects to the same page. Ig the link is broken? I tried to search for this minigrid.py file but could not find it. Possibly it has been renamed?

  2. why is there a discrepency between the grid size? I was expecting the grid size to be 8x8 for the environment MiniGrid-Empty-8x8-v0 however, the observation is for 7x7 tiles? Shouldn't it be for 8x8 tiles? And something weirder was in the visualization I could just see 6x6 tiles. I was not able to find any documentation on this as well. Or if it exisits I somehow missed it.

    Thank you for maintaining the repo! It's an awesome environment just needs a little bit of documentation update and clarity I think.

VineetTambe commented 1 year ago

An update on this:

  1. found the mappings here: constants.py (Should I go ahead and update the doc for it? )

  2. The 7x7 observation is the default vision of the agent?

BolunDai0216 commented 1 year ago

Yes, the documentation (not just for that single environment, but also for other environments) should be updated. If you can do a PR for that, that would be great!

Yes 7x7 observations is the default, see here.

VineetTambe commented 1 year ago

Will do!

BolunDai0216 commented 1 year ago

I will close this issue since there are no additional comments, please feel free to reopen it if anyone has any related questions.