chaofengc / IQA-PyTorch

👁️ 🖼️ 🔥PyTorch Toolbox for Image Quality Assessment, including LPIPS, FID, NIQE, NRQM(Ma), MUSIQ, TOPIQ, NIMA, DBCNN, BRISQUE, PI and more...
https://iqa-pytorch.readthedocs.io/
Other
1.94k stars 172 forks source link

How to pass the caption_list to clipscore method? #210

Closed huizhg closed 3 hours ago

huizhg commented 4 hours ago

Hi,

I am trying to get the image score from the clipscore method. But this model need a caption_list as a parameter. I tried:

metric = pyiqa.create_metric("clipscore", device=device)
score = metric(image_tensor, caption_list)

But I still get this error: _AssertionError: captionlist is None

huizhg commented 3 hours ago

It is solved by assigning the name of the parameter like: score = metric(image_tensor, caption_list=caption_list)