Closed CrHasher closed 1 year ago
Also noticed you probably don't support *.png files, is that true?
Thanks for your interest. The problem is neither because of OS nor the file format.
The metrics do not support images with 4 channels which have an extra alpha channel for transparency. I have updated the codes to make it read RGB format by default, you may use the latest codes with:
# Install latest github version
pip uninstall pyiqa # if have older version installed already
pip install git+https://github.com/chaofengc/IQA-PyTorch.git
# Install with git clone
git clone https://github.com/chaofengc/IQA-PyTorch.git
cd IQA-PyTorch
pip install -r requirements.txt
python setup.py develop
Besides, the codes are only tested with Ubuntu. It may also work on windows but I cannot guarantee that.
I managed to install this lib on Windows, but no matter what method I use 'MAD', 'LPIPS', 'DISTS' I always get different errors with every single one, so for me this lib on windows is unusable. Is Ubuntu a hard requirement to make this lib work?
Most frequent errors:
AssertionError: Input and reference images should have the same shape, but got torch.Size([1, 4, 1440, 2560]) and torch.
Which is not true all other methods from other libraries I tested work.RuntimeError: The size of tensor a (4) must match the size of tensor b (3) at non-singleton dimension 1
Probably some pytorch thing.To test I used inference_iqa.py
Thank you!