references/depth/stereo/utils/padder.py
Download source file: padder.py
import torch.nn.functional as Fclass InputPadder: """Pads images such that dimensions are divisible by 8""" # TODO: Ideally, this should be part of the eval transforms preset, instead # of being part of the validation code. It's not obvious what a good # solution would be, because we need to unpad the predicted flows according # to the input images' size, and in some datasets (Kitti) images can have