Fastai resize and tensorflow resize

I am using fastai’s ResizeMethod.PAD method, but when I use tensorflow’s tf.image.resize_image_with_pad to do resizing, I get different results, can anyone tell me what is ResizeMethod.PAD doing? it causes a lot of trouble when I try to productionize the model.