def METHOD_NAME(self, inputs: Input, **preprocess_params):
    img = LoadImage.convert_to_img(inputs)
    ori_size = [img.size[1], img.size[0]]
    image = self.transform(img)
    tensor_list = [image]
    orig_target_sizes = [ori_size]
    orig_target_sizes = torch.tensor(orig_target_sizes).to(self.device)
    samples = nested_tensor_from_tensor_list(tensor_list)
    samples = samples.to(self.device)
    res = {}
    res['tensors'] = samples.tensors
    res['mask'] = samples.mask
    res['orig_target_sizes'] = orig_target_sizes
    return res