Closed kywish closed 1 year ago
It is similar to applying 11x11 edge filter to 100x100 image. The result will be 90x90 image with detected edges. Resizing it to 100x100 would distort the detected edges. Instead you have to pad the 90x90 image with 5 pixels on each size.
Hi~, in the part of ouput anomaly map:
map_combined = torch.nn.functional.pad(map_combined, (4, 4, 4, 4)) map_combined = torch.nn.functional.interpolate(map_combined, (orig_height, orig_width), mode='bilinear')
why pad 4 pixel each side? what's the difference with resize to (orig_height, orig_width) directly? 🤔🤔🤔