SpatialGrid finally works but is slow
merging