prune#

anri.index.prune(U, delta, B, rings, geom, lit, min_comp=None, keep=100000)[source]#

Keep the grid orientations whose completeness passes a threshold.

The default threshold is halfway between chance (the grid’s median completeness) and the grid’s maximum.

Parameters:
Returns:

  • kept (np.ndarray) – [Nk] indices into U, most complete first

  • comp (np.ndarray) – [N] completeness of every grid orientation

  • info (dict) – “chance”, “min_comp”, “n_above” (orientations above the threshold) and “capped” (whether keep bit)