Open sin392 opened 4 years ago
Kerasを用いて、VGG16のモデルを転移学習させて切り出した画像から人の顔を判別するモデルをネットから探して実行してみた たしかに何かしらの特徴をつかんでいるかのような分類(同じ人の顔はおおむね1つのグループにまとめられた)を行っていたが、人の顔を判別はできなかった もうちょっとデータを集めてきちんと学習させてから判別するようにしていく
なるほど、opencvの方はhaarcascade使ったんですね。 VGGの方のレポートも待ってます。 可能だったら以下のような検出の様子も見てみたいです。
dlibでHOG&SVM(青)とCNN(赤)のテスト
dlib : mmod_human_face_detector (max margin object detection) https://github.com/davisking/dlib-models
upsample_num_times 2
→ window size 20×20
→ 3にするとOOM
実行時間 : 4s
メモリ消費量が多いのでモデル自体を変えたほうがいいかもしれない
@iso-jet yolov3やSSDといった物体検出モデルで顔検出をさせてみる @HimHim1113 非DL検出器→顔認識 を試してみる
pytorchのfacenet実装試してみた 検出モデル自体はMTCNNなのでさほど変わらないが...
confidence : thresholds=[0.6, 0.7, 0.7]
rects, preds = mtcnn.detect(img)... 0 0.9970695376396179 1 0.9621299505233765 2 0.999845027923584 3 0.9775848984718323 4 0.7722111344337463 5 0.9937999844551086 6 0.9953081011772156 7 0.9734599590301514 8 0.9878333806991577 9 0.7551294565200806 10 0.8822581171989441 11 0.9998670816421509 12 0.990210771560669
閾値の引き下げは誤検出が増えるだけだった
人物bboxと顔bboxの重なり(IoU)を見て色変え 他の人物とbboxが重なってる場合の処理を検討する必要あり
・IoUの参照の仕方を変更 ・face/person rateの表示
デフォルトのモデルでの結果
このモデルはcocoデータセットをもとに学習しており顔のラベルがなかったのでwider-faceの顔画像をもとに転移学習をさせることにした。 転移学習を試してみたが訓練の段階でエポック数がある一定数を超えるとlossがnanに飛んでしまう現象が起き、その調査中
目的
授業への関心や不満の指標として表情や視線を利用することを検討している。 前段階として、複数人の撮影動画に対する顔検出を試す。 必要に応じて転移学習等も行う。
前提条件
2 #9
完了条件
撮影動画に対して顔検出を行い、結果をレポートすること。
タスク