def METHOD_NAME(self, frame: np.ndarray):
    # Perform neighbourhood search if we got worse metric values
    if self._checking_neighbourhood:
        # Increment the neighbourhood index if we have finished checking the current neighbour pair
        if self._ir_grid_search_iteration(frame, self._neighbourhood_pairs, self._neighbour_idx):
            self._neighbour_idx += 1
    # Check if we have finished checking all candidates, done once on the start up
    elif not self._auto_ir_converged:
        # Increment the candidate index if we have finished checking the current candidate pair
        if self._ir_grid_search_iteration(frame, self._candidate_pairs, self._candidate_idx):
            self._candidate_idx += 1
    # Continuously check the consistency of the metric values, if we are in continuous mode
    elif self._auto_ir_converged and self.ir_settings['continuous_mode']:
        self._check_consistency(frame)