Thank you for the great work!
I got it working for my greyscale images since they are expanded to a three dimensional RGB image. But I wondered if its possible to simply change the code so the pipeline takes only one channel and computes faster (or even multiple channels > 3 for detection of 3D objects in series of concatenated Images).
And if yes, where do I have to change the code?
Thanks for the help!
how to solve it?
For processing single channel below changes should be done in the code
channels=1 in config/yolov3-custom.cfgline 47 and 86 in utils/datasets.py with desired image conversion modeimg = transforms.ToTensor()(Image.open(img_path).convert('1'))
https://pillow.readthedocs.io/en/stable/handbook/concepts.html#concept-modes
For point 2, the following change worked for me
img = transforms.ToTensor()(Image.open(img_path)
Most helpful comment
For processing single channel below changes should be done in the code
channels=1inconfig/yolov3-custom.cfgline 47 and 86inutils/datasets.pywith desired image conversion modehttps://pillow.readthedocs.io/en/stable/handbook/concepts.html#concept-modes