SoftwareGift / FeatherNets_Face-Anti-spoofing-Attack-Detection-Challenge-CVPR2019

Code for 3rd Place Solution in Face Anti-spoofing Attack Detection Challenge @ CVPR2019,model only 0.35M!!! 1.88ms(CPU)
Other
928 stars 282 forks source link

Demo script to classify one image #55

Open kadirbeytorun opened 5 years ago

kadirbeytorun commented 5 years ago

Hello, could you provide a simple script to classify a single image?

Really confused about the 1024 vector feature map, and all other issues are in chinese, so I dont know if anyone else asked about this.

Thanks in advance.

SoftwareGift commented 5 years ago

If you are only predicting a single image, you only need to take the first two categories of the category.

kadirbeytorun commented 5 years ago

Okay, but do what with them, give only two of them to softmax? Are they like preds[0]=fake, and preds[1]=real?

Also, do I need to detect face in the image first and then give the cropped face to network?

SoftwareGift commented 5 years ago

Okay, but do what with them, give only two of them to softmax? Are they like preds[0]=fake, and preds[1]=real?

Also, do I need to detect face in the image first and then give the cropped face to network?

yes, you are right.

kadirbeytorun commented 5 years ago

Results are wrong. Could you please explain more if its okay? Should I give normal rgb cropped face? Or do I need to use depth-rgb cropped faces? Regards

jeffryuiop commented 4 years ago

Hi, thank you for posting this. However, if i want to make an inference demo script for one image using your pretrained weight, How do I do that? After passing the two elements through a softmax, how do I interpret the result? Currently I have tried to use a real and fake cropped image and the result is more or less the same.

Once again, thank you and best regards.

SoftwareGift commented 4 years ago

https://github.com/SoftwareGift/FeatherNets_Face-Anti-spoofing-Attack-Detection-Challenge-CVPR2019/issues/72#issuecomment-548178960