clks-wzz/FAS-SGTD

Problems when testing.

Opened this issue · 4 comments

When I run test.py and change isOnline to False the following error occurs:

File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 284, in
offline_eval()
File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 275, in offline_eval
officialEval(os.path.join(flags.path.model, 'model.ckpt-%d'%(iter_now)))
File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 205, in officialEval
officialEvalSub(path_txt_dev, [flags.path.dev_file], 'dev', path_model_now)
File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 195, in officialEvalSub
fid.write(video_name_encode + ',' + str(video_score_mean) + '\n')
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'

Process finished with exit code 1

Please help to fix it. Thanks.

When I run test.py and change isOnline to False the following error occurs:

File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 284, in
offline_eval()
File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 275, in offline_eval
officialEval(os.path.join(flags.path.model, 'model.ckpt-%d'%(iter_now)))
File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 205, in officialEval
officialEvalSub(path_txt_dev, [flags.path.dev_file], 'dev', path_model_now)
File "/media/saeed/New Volume/PAD/Codes/FAS-SGTD/fas_sgtd_multi_frame/test.py", line 195, in officialEvalSub
fid.write(video_name_encode + ',' + str(video_score_mean) + '\n')
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'

Process finished with exit code 1

Please help to fix it. Thanks.

The main problem is that the for loop in this line would not be executed.

Thanks for your help in advance.

Maybe the dataset is not correctly written, so that the length of dataloader(test_input_fn) is zero. Please check it.

@clks-wzz @eesaeedkarimi @clks-wzz
Hi,

I would like to know about the test score, in the util_test_OULU_Protocol_1.py

the Testscor.txt, file

can you please tell me about that text file? how to generate those text files.

it will be a great help for my studies

hope for a reply

thank you

The for loop isn't getting executed because the features generator seems to be empty (it's length, when converted to a list, is 0). The reason for this could be:

features=mnist_classifier.predict( input_fn=eval_input_fn, checkpoint_path= path_model_now )

path_model_now is equal to './model_save/model.ckpt-19501' (I found this out by printing out the path while debugging), and no checkpoint file exists with such a name in the models being provided in this repo.
These are the only files that have been provided:
image

It would be helpful if the owners could clarify this.

P.S: I tried changing the names of a few files, but that isn't working.