Volume Estimation with D435 Depth-Camera
Hi, I've been working on trying to measure the volume of objects by using the D435 Camera. My question is how can I accomplish this task and what is the best setup of the camera in order to have the most accuracy possible?
I am developing a script on Python to work with the PointClouds extracted from the captures of the camera and then create a mesh to calculate the volume (I substract the volume of the mesh with the object and the volume without the object to have as ROI only the object), but the results are far away from the ground truth volume
Also I am using only one camera, but I checked some implementations of using various cameras placed strategically and with certain distance and angle differences to take all the volumetric capture
-
Hello, the RealSense SDK has a Python example program called box_dimensioner_multicam that works with a single camera despite the name. After the program is launched, the object to be measured is placed on a chessboard image on the ground. This program can be edited to work without a chessboard when used with one camera though.
If box_dimensioner_multicam is not suitable for your needs, alternative methods for volume estimation, including creating a mesh, are discussed at the link below.
https://github.com/IntelRealSense/librealsense/issues/4612#issuecomment-567375098
If using Python is not vital to your project, the RealSense Viewer tool has a Measure option in its 3D point cloud mode that can measure between more than two user-selected points on the point cloud by holding the shift key to connect multiple points and therefore estimate volume.
If you do need to use Python, an example of point to point measurement is the script at the link below that is a Python conversion of Intel's own rs-measure C++ example program.
https://github.com/soarwing52/RealsensePython/blob/master/separate%20functions/measure_new.py
-
In regard to accuracy: assuming that the camera is less than 3 meters from the observed object, setting the Medium Density camera configuration preset will give a good balance between accuracy and the amount of detail on the depth image.
If you do not mind the image losing some of the depth detail and becoming sparser, you could try the High Accuracy preset.
Please sign in to leave a comment.
Comments
2 comments