def METHOD_NAME(self, inputs):
    size = (self.height, self.width)
    if self.crop_to_aspect_ratio:
        outputs = image_utils.smart_resize(
            inputs,
            size=size,
            interpolation=self.interpolation,
            data_format=self.data_format,
            backend_module=self.backend,
        )
    else:
        outputs = self.backend.image.resize(
            inputs,
            size=size,
            interpolation=self.interpolation,
            data_format=self.data_format,
        )
    return outputs