select_from_grays
- select_from_grays(grays: list[numpy.ndarray], rects: list[list[int]], thresholds: list[int], empty: int, black: bool) dict[int, tuple[int | None, bool]][source]
For each area, pick the gray-frame index where only that area is occupied. Returns {area: (frame_index_or_None, isolated)}. isolated is True when a frame with the mouse alone in that area was found; False: returns best-effort fallback (max occupancy difference)