uf3.representation.distances.summarize_distances

summarize_distances(geometries: List[ase.atoms.Atoms], chemical_system: uf3.data.composition.ChemicalSystem, r_cut: float = 12.0, n_bins: int = 100, print_stats: bool = True, min_peak_width: float = 0.5, progress: Any = 'bar') Tuple[Dict, numpy.ndarray, Dict][source]
Construct histogram of distances per pair interaction across

list of geometries. Useful for optimizing the lower- and upper- bounds of knot sequences.

TODO: refactor to break up into smaller, reusable functions

Parameters
  • geometries (list) – list of ase.Atoms configuration.

  • chemical_system (uf3.composition.ChemicalSystem) –

  • r_cut (float) – cutoff distance in angstroms.

  • n_bins (int) – number of bins in histogram.

  • print_stats (bool) – print minimum distance and identified peaks.

  • min_peak_width (float) – minimum peak with in angstroms for peak-finding algorithm.

  • progress – style of progress bar.

Returns

for each interaction key (A-A, A-B, …),

vector of histogram frequencies of length n_bins. Frequency values are divided by r^2, evaluated at the middle of each bin.

bin_edges (np.ndarray): bin edges of histogram.

Return type

histogram_map (dict)