Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

benchark L515 encoding time with alignment #22

Closed
bmegli opened this issue Jul 3, 2020 · 4 comments
Closed

benchark L515 encoding time with alignment #22

bmegli opened this issue Jul 3, 2020 · 4 comments
Labels
maintenance Documentation and future-proof concepts

Comments

@bmegli
Copy link
Owner

bmegli commented Jul 3, 2020

L515 pipelines perform additional post-processing to simulate depth units and depth clamping.

From #18 on SBCs depth+color pipelines we already barely keep up with the data rate when performing alignment.

This may need some optimization.

@bmegli bmegli added the maintenance Documentation and future-proof concepts label Jul 3, 2020
@bmegli
Copy link
Owner Author

bmegli commented Jul 4, 2020

Scenario:

640x480 depth + 1280x720 color at 30 fps, 8Mb + 1 Mb bitrate, alignment to depth and color

#alignment to depth
./realsense-nhve-depth-color 192.168.0.100 9768 depth 640 480 1280 720 30 500 /dev/dri/renderD128 8000000 1000000 0.0000390625 short_range.json
#alignment to color
./realsense-nhve-depth-color 192.168.0.100 9768 color 640 480 1280 720 30 500 /dev/dri/renderD128 8000000 1000000 0.0000390625 short_range.json

With short_range.json exported from realsense-viewer ShortRange preset and removed lines that we set in RNHVE

{
    "Ambient Light": 2,
    "Apd Temperature": -9999,
    "Avalanche Photo Diode": 18,
    "Confidence Threshold": 1,
    "Depth Offset": 4.5,
    "Depth Units": 0.000250000011874363,
    "Error Polling Enabled": 1,
    "Frames Queue Size": 16,
    "Freefall Detection Enabled": 1,
    "Global Time Enabled": 0.0,
    "Inter Cam Sync Mode": 0.0,
    "Invalidation Bypass": 0.0,
    "Laser Power": 87,
    "Lld Temperature": 45.3513870239258,
    "Ma Temperature": 43.7060546875,
    "Mc Temperature": 43.8653526306152,
    "Min Distance": 190,
    "Noise Filtering": 3,
    "Post Processing Sharpening": 1,
    "Pre Processing Sharpening": 0.0,
    "Sensor Mode": 0.0,
    "Visual Preset": 5,
    "Zero Order Enabled": 0.0
}

@bmegli
Copy link
Owner Author

bmegli commented Jul 4, 2020

Results

Alignment to depth

./realsense-nhve-depth-color 192.168.0.100 9768 depth 640 480 1280 720 30 500 /dev/dri/renderD128 8000000 1000000 0.0000390625 short_range.json
  • post processing between 2-5 ms, typically 2-3 ms
  • whole time between 22-33 ms, typically below 28 ms
  • CPU usage around 60% of 800% (as reported by htop)

Alignment to color:

./realsense-nhve-depth-color 192.168.0.100 9768 color 640 480 1280 720 30 500 /dev/dri/renderD128 8000000 1000000 0.0000390625 short_range.json
  • post processing between 2-8 ms, typically 4-6 ms
  • whole time between 32-50 ms, typically exceeds 33 ms
  • CPU usage around 60% of 800% (as reported by htop)

@bmegli
Copy link
Owner Author

bmegli commented Jul 4, 2020

Discussion

Alignment to color is more time consuming. The reason is that that we end up with target resolution (1280x720 for color, 640x480 for depth). Also the resulting depth map when aligning to color will be 1280x720. This is somewhat representative for what we would get with L515 XGA depth (1024x768 ).

On laptop we keep up with the data rate when aligning to smaller depth (typically < 28 ms) and don't keep up when aligning to larger color (typically exceeds 33 ms a lot).

It is clear that we would also have problems on weaker SBC when aligning to color so this test is skipped.

Current naive depth post processing takes a few ms (2-3 or 4-6 for larger data).

@bmegli
Copy link
Owner Author

bmegli commented Jul 4, 2020

Conclusion

Looking at results naive post-processing takes < 5 ms. Comparing to #18 it is clear that the main villain is alignment for the larger resolution (1280x720 now vs 848x480 for D435).

L515 colored aligned depth pipeline is not usable in realtime at 30 FPS.

Depth aligned would vary between hardware.

L515 depth+color pipelines need optimization.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Documentation and future-proof concepts
Projects
None yet
Development

No branches or pull requests

1 participant