bug fixing for grid.py