Find (spatially) neighboring atoms in a trajectory.
Given a set of query_indices representing and a distance cutoff, compute the indices of all atoms whose distance to 1 or more of the query points is less than cutoff.
Parameters: | traj : md.Trajectory
cutoff : float
query_indices : np.ndarray, shape=(n_query_indices,), dtype=int
haystack_indices : np.ndarray, shape=(n_query_indices,), dtype=int, optional
periodic : bool
|
---|---|
Returns: | matches : list of np.ndarray, shape=(n_matches,), dtype=int
|