the GMM_score is not between [0, 1]
chensjtu opened this issue · 4 comments
hello! i use your gmm code and get the score of the imgs is pretty marvious. Does there any steps i got wrong?
......
score of 114.jpg is:
12225.555544777117
score of 453.jpg is:
12162.200271020361
score of 343.jpg is:
12085.507695046039
score of 306.jpg is:
12251.0952301596
score of 438.jpg is:
12138.23795022325
score of 246.jpg is:
12085.50769569048
score of 339.jpg is:
12225.455868995597
score of 315.jpg is:
12218.148844663554
score of 261.jpg is:
12225.455868975976
score of 82.jpg is:
12085.507697492993
score of 342.jpg is:
12225.555544856654
score of 334.png is:
12218.14884460266
score of 263.png is:
12217.426774743915
score of 63.png is:
12085.507696855651
score of 382.png is:
-46069728.00091776
score of 222.png is:
12250.923218525548
score of 221.png is:
12251.13040117361
score of 270.png is:
12186.212538611771
score of 414.png is:
-25461121.514812943
score of 434.png is:
-61937752.13751065
score of 47.png is:
-82769187.2630152
score of 354.png is:
-87741719.93647467
score of 276.png is:
12217.522549181807
score of 422.png is:
-39031307.403086096
score of 4.png is:
-34059555.85986152
score of 367.png is:
-67440733.50017826
score of 387.png is:
12162.200272076472
score of 362.png is:
-45590348.13169143
score of 1.png is:
12087.937832531064
......
the step is :first use write_act.py to get act.pkl. and then 'get_gmm.py' and 'gmm_score.py'. finally i get these results with 'results.txt'
It's a bit strange. Could you provide more details? What is the training images to get act.pkl, the number of GMM kernel densities, if you use PCA in your GMM model, the file size of your GMM model, and the most important thing is, i think it's better for you to provide each images, then maybe i will know if them are right.
the INPUT command is :
python write_act.py ../512generatedimg/ --act_path act.pkl --pca_path pca.pkl --gpu 0,1
(250, 2048)
python get_gmm.py --act_path act.pkl --kernel_number 70 --gmm_path gmm.pkl
python gmm_score.py ../512_test/ --gmm_path gmm.pkl --output_file gmm_result.txt --gpu 0,1 --pca_path pca.pkl
tail -100f gmm_results.txt
the train and test dataset is here:https://drive.google.com/file/d/1jrjoZ4QCljmPqkKy39UXPNiXs7NvmHAq/view?usp=sharing
That make sense. There are some problems in your example:
- Your training images only contain 284 images to build GMM model, It's not enough. We suggest for a generated image, you need all the training images to build the GMM, for example, if the training set contain 70000 images(like FFHQ), you need to use all of them to build GMM. otherwise, the GMM may not contain enough information. Sufficient training data are extremely important for GMM-GIQA. Maybe you can use KNN-GIQA in this case.
- If you do not need pca, the pca_path can leave blank.
- The results are not in [0,1] is reasonable. For data-based GIQA( including GMM-GIQA ), we use the probability in real distribution to indicate the quality. But notice that this probability function is actually density function, so it may over 1. So the log of probability may bigger than 1 or smaller than 0.
Many thanks for your response in detail! i'll try the whole dataset for evaluation.