Hello Intel community, I am doing my master thesis in 3d reconstruction of apple plantation and I am using the Intel Realsense D435 camera to make this reconstruction. I read that this type of camera can work outdoor but when I use it to get the point cloud of the trees It gives me weired things rather than what is shown in realsense_viewer. I tried in my python code to adjust the depth_units but nothing enhanced.
My project is requiring the point cloud to apply ICP (Iterative closest point) algorithm in order to register all the point clouds that I saved from the camera.
Here is the python code that I used to save the .ply files to use it after that in the registartion it gives excellent results in indoor but in outdoor the results is really bad.
# First import the library
import pyrealsense2 as rs
from pynput import keyboard
counter = 0
if key == keyboard.Key.space:
counter += 1
if key == keyboard.Key.esc:
# Stop listener
if __name__ == '__main__':
pipe = rs.pipeline()
config = rs.config()
align_to = rs.stream.color
align = rs.align(align_to)
profile = pipe.start(config)
device = profile.get_device()
depthsensor = device.first_depth_sensor()
# This value in realsense viewer in micrometers and here is in meters
frames = pipe.wait_for_frames()
aligned_frames = align.process(frames)
aligned_depth_frame = aligned_frames.get_depth_frame()
color_frame = aligned_frames.get_color_frame()
pc = rs.pointcloud()
points = rs.points()
points = pc.calculate(aligned_depth_frame)
# Collect events until released
with keyboard.Listener(on_press=on_press,on_release=on_release) as listener:
listener = keyboard.Listener(on_press=on_press,on_release=on_release)
Here is the rgb and depth images:
When I try to use the realsense_viewer and export the .ply file i got this:
but when I used my python code I got this:
My objective is to get the depth and color streams and then use the generated point cloud to save different point clouds of the scene and then use the ICP to get the full point cloud of the scene.
Is there any suggestions to make this project work either by ROS or by the SDK?
Please sign in to leave a comment.