removed extraneous np.where function