View my account

Is depth broken in my SR305

Comments

22 comments

  • MartyG

    At the top of the options side panel, is the name of the camera shown as 'SR300' instead of SR305, please?  If it is, please go to the 'More' button just below the name and select from its drop-down menu the option to update to recommended firmware.

    0
    Comment actions Permalink
  • Brad Colbert

    It does say SR300 but when I select the more button and "Update Firmware" it brings up a file selection dialogue.  I don't have a firmware update file and I couldn't find one by searching.

    0
    Comment actions Permalink
  • MartyG

    Have you ever run a driver installation program called the Depth Camera Manager or DCM since you bought your SR305?

    0
    Comment actions Permalink
  • Brad Colbert
    I haven’t, no. I opened the box yesterday and freshly installed the RS software for Ubuntu 18.04.
     
    Today I installed and ran on Windows 10.  The behavior is more to what I would expect although it still reports it as an SR300:
     
     
    Just so you know, I also own a 400 model RS. I’ve had that for some time.
    0
    Comment actions Permalink
  • MartyG

    It is unusual that your SR305 is being detected as an SR300 but not necessarily bad.  In fact, some people prefer getting their SR305 to be detected as an SR300 so that the camera works with old programs that support SR300 but may have problems when the camera identifies itself as SR305.

    Do you still need to get the camera to work as desired on the first computer that you tried it on or are you happy to use it on Windows 10, please?

    0
    Comment actions Permalink
  • Brad Colbert

    Hi Marty,

    Linux is preferred.  I still haven't verified if it's a problem with the realsense-viewer or the actual depth values are clamped.  Maybe that is next?  Or is this something that you suspect may run deeper?

    0
    Comment actions Permalink
  • MartyG

    I am reminded of a case in the past week where somebody said that the 3D point cloud depth was not being displayed correctly if CUDA graphics mode was enabled.  Do you know whether you have Nvidia CUDA graphics on your Linux computer, please?

    0
    Comment actions Permalink
  • Brad Colbert

    Definitely have Nvidia (GTX 1080) and Cuda is installed.  Not sure if the any of the RL libraries were using CUDA, however.

    0
    Comment actions Permalink
  • MartyG

    In general, if Librealsense is being built from source then you have to deliberately enable CUDA support in the CMake build instruction, as it is False by default. 

    If Librealsense is installed with a Debian package then CUDA support is already included in the package.

    0
    Comment actions Permalink
  • Brad Colbert

    Is it possible to disable the use of CUDA by librealsense?  I need CUDA for other things.

     

    Thanks!

    0
    Comment actions Permalink
  • MartyG

    The SR305 user in the case I mentioned earlier found that by editing one Librealsense file to disable CUDA in that file only, they could fix the broken depth.  They created a forked version of the SDK with the fix built in to make it easier for other SR305 users to replicate.

    https://github.com/IntelRealSense/librealsense/issues/6373#issuecomment-630584604 

     

    0
    Comment actions Permalink
  • Brad Colbert

    From that, I would guess that I'm the second case of this happening and it appears to be related to CUDA and maybe the issue shouldn't be closed.

    0
    Comment actions Permalink
  • MartyG

    I have re-opened that case for further investigation.

    0
    Comment actions Permalink
  • Brad Colbert

    I'd be happy to help.  I'm assuming it's compile time IFDEF'd in/out?  Do you use cmake for the build builder?

    0
    Comment actions Permalink
  • Brad Colbert

    Converting to a runtime getenv() might be more flexible.

    0
    Comment actions Permalink
  • Brad Colbert

    Well, apparently his code was committed but probably not the best solution...

     

    #ifdef RS2_USE_CUDA_NOT
    #include "cuda/cuda-conversion.cuh"
    #endif
    0
    Comment actions Permalink
  • MartyG

    Brad Colbert  Thanks very much.  Documentation on how Librealsense uses CMake as a standard mechanism for building is available at the link below:

    https://github.com/IntelRealSense/librealsense/wiki/Build-Configuration 

     

    Edit: I am off-shift for the day now but will be back in 7 hours from the time of writing this and will be happy to continue the support conversation.   Good luck!

    0
    Comment actions Permalink
  • Brad Colbert

    Yep, got it.  I'm digging into it but have some quick questions mainly about how often some calls are called:

     

    Specifically these:

    unpack_z16_y8_from_sr300_inzi()
    unpack_z16_y16_from_sr300_inzi()
    std::shared_ptr<pointcloud> pointcloud::create()

    I'm adding a getenv() switch that allows you to set an environment variable to disable CUDA use even if you compiled it in.  getenv() isn't horribly expensive but it's not free, so would prefer to make sure it isn't called 1000X per frame.

     

     

     

     

     

    0
    Comment actions Permalink
  • Brad Colbert

    I added this code at critical CUDA segments:

    if(!getenv("RS2_DISABLE_CUDA")) {

    If disabled I copied the code in the #else clause or used the SSE code.

    Without CUDA disabled:

    With RS2_DISABLE_CUDA defined:

     

    0
    Comment actions Permalink
  • MartyG

    Thanks for the effort that you have put into debugging this problem!

    I do not have information on unpack_z16.  I notice though that in the Viewer you are getting a warning message about multiple udev rules being detected, which is a problem in itself.  A RealSense team member gives advice for fixing it in the link below.

    https://github.com/IntelRealSense/librealsense/issues/6153#issuecomment-605687547 

     

     

    0
    Comment actions Permalink
  • Brad Colbert

    Hi Marty,

    Should I move these questions to the librealsense github?  Should I propose to submit my modest changes that make the use of CUDA optional at runtime?

    0
    Comment actions Permalink
  • MartyG

    In general it is fine to post RealSense questions here instead of the GitHub.  The exceptions are feature requests or RealSense T265 questions - those should be posted on the GitHub.  If the question is about programming then the GitHub is also an excellent place to post.

    0
    Comment actions Permalink

Please sign in to leave a comment.