Face Detection
The test program will pull the camera data, add the face detection algorithm, and use tools such as VLC to pull the stream in real time to view the effect.
Compilation
Face detection program source code location:
-
Duo:sample_vi_fd.c
-
Duo256M and DuoS:sample_vi_fd.c
Refer to the method in the previous chapter Introduction to compile the sample program.
Send test program and model files to Duo
-
Refer to the method in the Boot the Duo chapter to install the system
-
Refer to the method in the Camera chapter to power on the Duo after connecting the camera
Send the compiled sample_vi_fd
to the Duo board through the scp
command on your PC:
scp sample_vi_fd [email protected]:/root/
Also use scp to send the model file used for face detection in the cvimodel
directory to the Duo board:
Duo:
scrfd_480_270_int8.cvimodel
Duo256M and DuoS:
scrfd_768_432_int8_1x.cvimodel
Run the example
Log in to the Duo terminal through the serial port or ssh.
Add executable permissions to the test program in Duo's terminal
chmod +x sample_vi_fd
Execute the test program in Duo's terminal:
Duo:
./sample_vi_fd scrfd_480_270_int8.cvimodel