Items with no label
3335 Discussions

How to use D435 in python2

ycao6
New Contributor I
3,293 Views

I have successfully installed pyrealsense2 in my python3 environment, but my own project is running with python2 and I want to combine the Depth Image from D435 to my project , what should I do?

pyrealsense2 doesn't work in SDK2.0, so should I use SDK1.0 with my D435 camera , and install pyrealsense2.0 ?

0 Kudos
1 Solution
ycao6
New Contributor I
1,572 Views

" import pyrealsense2 " works for me now in my python2 environment. The issue below is the key to solve it .

https://github.com/IntelRealSense/librealsense/issues/793 Unable to import pyrealsense2 on python · Issue # 793 · IntelRealSense/librealsense · GitHub

View solution in original post

0 Kudos
12 Replies
ycao6
New Contributor I
1,573 Views

" import pyrealsense2 " works for me now in my python2 environment. The issue below is the key to solve it .

https://github.com/IntelRealSense/librealsense/issues/793 Unable to import pyrealsense2 on python · Issue # 793 · IntelRealSense/librealsense · GitHub

0 Kudos
MartyG
Honored Contributor III
1,572 Views
0 Kudos
RTasa
New Contributor I
1,572 Views

Marty, that example is fantastic. Its almost what I want to do, just further away.

0 Kudos
MartyG
Honored Contributor III
1,572 Views

Glad it may be of use to you, Bob.

0 Kudos
ycao6
New Contributor I
1,572 Views

Hi, I am facing another problem now ,here is my depth image, but it is not so clear and satisfied, what should I do to adjust it ? if there is any tutorial I can learn about the adjustment ? Thank you for your help !

0 Kudos
MartyG
Honored Contributor III
1,572 Views

Looking at your image, the first thing I would try is to reduce the Laser Power slider in the RealSense Viewer to try to reduce the black dots on your body.

0 Kudos
RTasa
New Contributor I
1,572 Views

All cameras have noise in the pixels. There is an image processor selection that allows you to blur the image so that you get less pixel drop out.

I have noticed the software has issues of corners and edges. Doorway edges and corners have infinite distance, have no idea why.

Been meaning to ask about this but am in a hurry to do other things.

0 Kudos
MartyG
Honored Contributor III
1,572 Views

Bob, you and cyyyyy may be interested in a new post-processing tutorial for Python called 'depth_filters' that was added to Intel's new tutorial system yesterday.

https://github.com/IntelRealSense/librealsense/tree/jupyter/notebooks librealsense/notebooks at jupyter · IntelRealSense/librealsense · GitHub

The example is also available in an interactive Jupyter cloud container format.

https://mybinder.org/v2/gh/IntelRealSense/librealsense/jupyter?filepath=notebooks/depth_filters.ipynb https://mybinder.org/v2/gh/IntelRealSense/librealsense/jupyter?filepath=notebooks/depth_filters.ipynb

0 Kudos
RTasa
New Contributor I
1,572 Views

Although that addresses the basic issue I wonder there are so many huge drop outs?

Isn't it using stereo graphic algorithms?

You can see it in the image clearly enough. Do you have any idea why?

I a reasonably lit room you loose corners and doorways?

0 Kudos
MartyG
Honored Contributor III
1,572 Views

Problems with reading edges and surfaces with low detail have existed as long as RealSense has. It is not an issue specific to RealSense types of depth camera though. There have always been little tricks that you can do in order to make surfaces more readable by the camera. These include putting some complex-shaped objects in the camera view to provide more geometry for the camera to lock on to, or placing a background behind the objects to act as a 'horizon' for the scene.

Artec offer some similar tips:

https://artecgroup.zendesk.com/hc/en-us/articles/205049442-Objects-with-repetitive-geometry-and-no-texture Objects with repetitive geometry and no texture – Artec Support Center

The IR projector on a 400 Series camera can provide texture in scenes that contain a low amount of texture by projecting a random dot pattern onto the scene. Apparently, using multiple cameras provides even more texture to the scene (and so greater depth accuracy) because of the increased number of projected dots in the scene when you have more than one camera present.

0 Kudos
ycao6
New Contributor I
1,572 Views

Thank you for your response !!

Is the usb3.1&type-c cable always suitable for the camera? the cable in the camera box is too short and tough , I want to use another one

0 Kudos
MartyG
Honored Contributor III
1,572 Views

The type of cables used with the camera (USB Type-C) can sometimes have quality problems that make the camera work less than its best or not at all if you buy a different cable to replace the Intel-supplied short one. A supplier of cables shown to work well with the 400 Series cables is Newnex.

https://www.youtube.com/watch?v=GLQgR1jT04M USB Extension for Intel RealSense D400 Series Camera - YouTube

0 Kudos
Reply