def METHOD_NAME(self, img):
    img = LoadImage.convert_to_ndarray(img)
    height, width = img.shape[:2]
    self.ratio = min(self.test_size[0] / img.shape[0],
                     self.test_size[1] / img.shape[1])
    img, _ = self.preproc(img, None, self.test_size)
    img = torch.from_numpy(img).unsqueeze(0)
    img = img.float()
    # Video decoding and preprocessing automatically are not supported by Pipeline/Model
    # Sending preprocessed video frame tensor to GPU buffer self-adaptively
    if next(self.model.parameters()).is_cuda:
        img = img.to(next(self.model.parameters()).device)
    return img