def certify(
        self,
        x: np.ndarray,
        patch_size: float = 0.01,
        offset: float = 0.1,
        batch_size: int = 128,
    ) -> list[np.ndarray]:
        """
        Checks if there is certifiable IoA robustness for each predicted bounding box.

        :param x: Sample input with shape as expected by the model.
        :param patch_size: The size of the patch to check against.
        :param offset: The offset to distinguish between the far and near patches.
        :return: A list containing an array of bools for each bounding box per image indicating if the bounding
                 box is certified against the given patch.
        """
        height, width = self._image_dimensions()

        patch_size = np.sqrt(height * width * patch_size)
        height_offset = offset * height
        width_offset = offset * width

        # Get predictions
        predictions = self.predict(x, batch_size=batch_size)

        certifications: list[np.ndarray] = []

        for pred in tqdm(predictions, desc="ObjectSeeker", disable=not self.verbose):
            boxes = pred["boxes"]

            # Far patch
            far_patch_map = np.ones((len(boxes), height, width), dtype=bool)
            for i, box in enumerate(boxes):
                x_1 = int(max(0, box[1] - patch_size - height_offset))
                x_2 = int(min(box[3] + height_offset + 1, height))
                y_1 = int(max(0, box[0] - patch_size - width_offset))
                y_2 = int(min(box[2] + width_offset + 1, width))
                far_patch_map[i, x_1:x_2, y_1:y_2] = False
            far_vulnerable = np.any(far_patch_map, axis=(-2, -1))

            # Close patch
            close_patch_map = np.ones((len(boxes), height, width), dtype=bool)
            for i, box in enumerate(boxes):
                x_1 = int(max(0, box[1] - patch_size))
                x_2 = int(min(box[3] + 1, height))
                y_1 = int(max(0, box[0] - patch_size))
                y_2 = int(min(box[2] + 1, width))
                close_patch_map[i, x_1:x_2, y_1:y_2] = False
            close_vulnerable = np.any(close_patch_map, axis=(-2, -1))

            # Over patch
            close_patch_map = np.ones((len(boxes), height, width), dtype=bool)
            for i, box in enumerate(boxes):
                x_1 = int(max(0, box[1] - patch_size))
                x_2 = int(min(box[3] + 1, height))
                y_1 = int(max(0, box[0] - patch_size))
                y_2 = int(min(box[2] + 1, width))
                close_patch_map[i, x_1:x_2, y_1:y_2] = True
            over_vulnerable = np.any(close_patch_map, axis=(-2, -1))

            cert = np.logical_and.reduce((far_vulnerable, close_vulnerable, over_vulnerable))
            certifications.append(cert)

        return certifications

        Checks if there is certifiable IoA robustness for each predicted bounding box.

        :param x: Sample input with shape as expected by the model.
        :param patch_size: The size of the patch to check against.
        :param offset: The offset to distinguish between the far and near patches.
        :return: A list containing an array of bools for each bounding box per image indicating if the bounding
                 box is certified against the given patch.
        
art/estimators/certification/object_seeker/object_seeker.py