`_nearest_neighbor` can be optimized for speed when using large networks by restricting the operation to be within a max search distance.