How to acess nvinfer's padding/scaling data with maintain-aspect-ratio=1

If you are using nvdspreprocess, then nvinfer will directly process the tensor generated by nvdspreprocess(it is called NVDS_PREPROCESS_BATCH_META in deepstream) without aligning the image.

Refer to the block diagram of nvinfer/nvdspreprocess below.

If you want to achieve image warping in nvdspreprocess, I think you can modify CustomTransformation/CustomAsyncTransformation in /opt/nvidia/deepstream/deepstream/sources/gst-plugins/gst-nvdspreprocess/nvdspreprocess_lib/nvdspreprocess_lib.cpp