AIZOOTech / FaceMaskDetection

开源人脸口罩检测模型和数据 Detect faces and determine whether people are wearing mask.
https://demo.aizoo.com/face-mask-detection.html
MIT License
2.08k stars 618 forks source link

Tensor shape problem #59

Open AniketSindhu opened 4 years ago

AniketSindhu commented 4 years ago

Hey, I was trying to use your mask detector model for my app.I am a beginner. I took the tflite model from the repo and try to use it on my flutter app but it is throwing me some error(attached in image). I think that's because of the output array can I know what is the output array. I tried using face, face_mask, Mask,NoMask none of them work for me please help, and thanks for the model. hoping for a reply soon 969F744D-332A-4A28-9DF9-DC54CB0E1A7A

AIZOOTech commented 4 years ago

In tflite android example, the object detection model is completed, it contains model forward, output decode and nms, however, our model only have the model forward process, you need to write the corresponding decode and nms codes. You can use our open source dataset to train a model with tensorflow object detection api. We alse train a model with it. If you want to use ti, you can send one email to jianghongliang@aizoo.com

AniketSindhu commented 4 years ago

Ok got it! sent an email for the model thanks a lot.

AniketSindhu commented 4 years ago

by any chance, you have separated data of both the classes, I mean in a different folder. the mask images in one folder and without the mask in another.

AIZOOTech commented 4 years ago

@AniketSindhu I split the data to trainset and testset, not face mask or face without mask.

simonbuehler commented 4 years ago

.., our model only have the model forward process, you need to write the corresponding decode and nms codes...

whats the reason or benefit of having the deocde / nms handling not in the model but in the application code?

AniketSindhu commented 4 years ago

please, someone, provide me the tflite model of this I want to make an android application.

AIZOOTech commented 4 years ago

.., our model only have the model forward process, you need to write the corresponding decode and nms codes...

whats the reason or benefit of having the deocde / nms handling not in the model but in the application code?

I trained this model with keras and tensorflow and convert the model to Caffe、PyTorch、MXnet,in order to convert the model conveniently, I cannot wirte all the decode, nms process to the model. So I decide to do the decode and nms process with python.