Changed impassible grid into ndarray