Deepstream app use retinaface and arcface for face recognition.
This is a face detection and recognition app build on Deepstream.
Follow deepstream official doc to install dependencies.
Deepstream docker is more recommended.
Please refer to links below for pretrained models and serialized TensorRT engine. Or download from Google driver.
there should be a face alignment before arcface. Use a custom-gst-nvinfer to preprocess the tensor-meta of retinaface.
set a larger face detection bbox so that we can do alignment better later.
cd models/retinaface
make
Then set "ip;port;topic" in codes. e.g.
DSFace("localhost;9092;deepstream")
you can recieve result messages on deepstream topic and error messages on error topic in same ip&port.
cd test
python3 face_test_demo.py
Notice that only support RTSP stream and Gstreamer format.
images before and after alignment will be stored in images.
modify codes in test/cal_sim.py. replace with your own face-feature npy file.
python3 test/cal_sim.py
it will outputs all score.