def METHOD_NAME(self,
                   name: str,
                   image: np.ndarray,
                   data_sample: Optional['TextRecogDataSample'] = None,
                   draw_gt: bool = True,
                   draw_pred: bool = True,
                   show: bool = False,
                   wait_time: int = 0,
                   pred_score_thr: float = None,
                   out_file: Optional[str] = None,
                   step=0) -> None:
    """Visualize datasample and save to all backends.
    - If GT and prediction are plotted at the same time, they are
    displayed in a stitched image where the left image is the
    ground truth and the right image is the prediction.
    - If ``show`` is True, all storage backends are ignored, and
    the images will be displayed in a local window.
    - If ``out_file`` is specified, the drawn image will be
    saved to ``out_file``. This is usually used when the display
    is not available.
    Args:
        name (str): The image title. Defaults to 'image'.
        image (np.ndarray): The image to draw.
        data_sample (:obj:`TextRecogDataSample`, optional):
            TextRecogDataSample which contains gt and prediction.
            Defaults to None.
        draw_gt (bool): Whether to draw GT TextRecogDataSample.
            Defaults to True.
        draw_pred (bool): Whether to draw Predicted TextRecogDataSample.
            Defaults to True.
        show (bool): Whether to display the drawn image. Defaults to False.
        wait_time (float): The interval of show (s). Defaults to 0.
        out_file (str): Path to output file. Defaults to None.
        step (int): Global step value to record. Defaults to 0.
        pred_score_thr (float): Threshold of prediction score. It's not
            used in this function. Defaults to None.
    """
    height, width = image.shape[:2]
    resize_height = 64
    resize_width = int(1.0 * width / height * resize_height)
    image = cv2.resize(image, (resize_width, resize_height))
    if image.ndim == 2:
        image = cv2.cvtColor(image, cv2.COLOR_GRAY2RGB)
    cat_images = [image]
    if (draw_gt and data_sample is not None and 'gt_text' in data_sample
            and 'item' in data_sample.gt_text):
        gt_text = data_sample.gt_text.item
        cat_images.append(self._draw_instances(image, gt_text))
    if (draw_pred and data_sample is not None
            and 'pred_text' in data_sample
            and 'item' in data_sample.pred_text):
        pred_text = data_sample.pred_text.item
        cat_images.append(self._draw_instances(image, pred_text))
    cat_images = self._cat_image(cat_images, axis=0)
    if show:
        self.show(cat_images, win_name=name, wait_time=wait_time)
    else:
        self.add_image(name, cat_images, step)
    if out_file is not None:
        mmcv.imwrite(cat_images[..., ::-1], out_file)
    self.set_image(cat_images)
    return self.get_image()