get_fingerprint_distance

emmet.core.featurization.robocrys.condense.fingerprint.get_fingerprint_distance(structure_a, structure_b)

Gets the euclidean distance between the fingerprints of two structures.

Return type:

float

Parameters:
  • structure_a (IStructure | Iterable)

  • structure_b (IStructure | Iterable)

Args:
structure_a: The first structure or fingerprint. Can be provided as a

structure or a fingerprint. If provided as a structure, the fingerprint will be calculated first, so generally it is quicker to pre-calculate the fingerprint if comparing against multiple structures in turn.

structure_b: The second structure or fingerprint. Can be provided as a

structure or a fingerprint. If provided as a structure, the fingerprint will be calculated first, so generally it is quicker to pre-calculate the fingerprint if comparing against multiple structures in turn.

Returns:

The euclidean distance between fingerprints as a numpy.ndarray.