how to find length of the particular object (from front up to back of the image ) in real time using pyrealsense2 with opencv-python
I am creating a face detection python project using pyrealsense2 with opencv-python. in that i need to find whether the face in front of camera I am showing is real person not an image. for that I need to find the length of the face so that I can verify whether it is image or real person's face or give me any suggestions for this usecase. hope I will get help asap.
-
Hi Revathi A new RealSense facial authentication system called RealSense ID is shipping in the first week of March 2021, so this could provide a ready-made RealSense face detection solution.
https://store.intelrealsense.com/buy-intel-realsense-id-solution-f455-for-facial-authentication.html
If you would prefer to create your own solution in Python, the Dlib face detection library may be useful for creating an anti spoofing solution. It was made for C++ but supports Python. If you go to the link below and find the "Help / Info" section in the side-panel, expanding open the Examples: Python section shows a list of Dlib face sample programs for Python.
A RealSense team member in another case also recommended the Dlib approach, suggesting to google for the term facial-landmarks-dlib-opencv-python
https://github.com/IntelRealSense/librealsense/issues/4430#issuecomment-511660804
You could also take the approach of measuring between two points on the image, as suggested in your question. A RealSense user called soarwing52 developed a Python conversion of the RealSense SDK's rs-measure example program for point to point measurement.
https://github.com/soarwing52/RealsensePython/blob/master/separate%20functions/measure_new.py
Please sign in to leave a comment.
Comments
2 comments