Add the following lines to the _mazeenv.py:
if not(next_rowcol in next_visit): next_visit.append(next_rowcol)
This should be added to the lines 338 and 339 respectively.
Motivation
In my experiments on larger maps (40x40 rows and columns) sometimes the BFS search starts adding the same nodes to the _tovisit
list. The to visit list grows to large, containing billions of elements.
Pitch
I suggest a simple fix to check if the element already exists in the _tovisit list before adding it to the list.
Proposal
Add the following lines to the _mazeenv.py:
if not(next_rowcol in next_visit): next_visit.append(next_rowcol)
This should be added to the lines 338 and 339 respectively.Motivation
In my experiments on larger maps (40x40 rows and columns) sometimes the BFS search starts adding the same nodes to the _tovisit list. The to visit list grows to large, containing billions of elements.
Pitch
I suggest a simple fix to check if the element already exists in the _tovisit list before adding it to the list.
Additional context
e](https://github.com/Farama-Foundation/d4rl/issues) in the repo (required)