Open wennyHou opened 1 year ago
CAT-Net requires a JPEG image as input but the inference code automatically converts a non-JPEG image to JPEG at the very beginning.
@CauchyComplete Do we need to convert all the images into jpg before training? If yes, why there are still images with .tiff and .png extension in the lists you provided. Please response to this query as I am getting the following error.
[LIBJPEG ERROR]: Not a JPEG file: starts with 0x49 0x49
[LIBJPEG] Error occurs during reading file.
Traceback (most recent call last):
File "D:\ImageManipulation\CAT-Net-main\CAT-Net-main\tools\train.py", line 233, in
In the inference dataset(dataset='arbitrary'), non-JPEG images are automatically converted to JPEG files and plugged into the model: https://github.com/mjkwon2021/CAT-Net/blob/f1716b0849eb4d94687a02c25bf97229b495bf9e/tools/infer.py#L75
During training, we should manually convert them into JPEG files.
I implemented it like this for speed-up training because training uses converted files multiple times.
When inference, do I need to convert image to jpg format first? Thanks