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

Apply particle scattering effect to lidars #252

Merged
merged 6 commits into from
Feb 17, 2021
Merged

Conversation

iche033
Copy link
Contributor

@iche033 iche033 commented Feb 17, 2021

depends on #251

Summary

Lidars detect particles as large blocky squares due to the way particles are rendered in ogre (2d sprites / billboard). This PR applies scattering effect in a similar way as it's done for the depth camera in pull request #251. Whenever a ray in the lidar intersects with a particle, there is a chance that it'll miss or become scattered (by adding Gaussian noise).

Test it

  • Launch ign-gazebo with this sensor_particles.sdf world.
  • Open the Visualize Lidar gui plugin (open top right menu and select Visualize Lidar
  • Hit refresh button next to the topic drop down list in the Visualize Lidar plugin to see the /lidar topic
  • Hit Play to see lidar visualization.

lidar_particles

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge

@iche033 iche033 added ogre2.x 🔮 dome Ignition Dome labels Feb 17, 2021
@iche033 iche033 requested a review from adlarkin February 17, 2021 00:32
@codecov
Copy link

codecov bot commented Feb 17, 2021

Codecov Report

❗ No coverage uploaded for pull request base (depth_particles@733bc91). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@                Coverage Diff                 @@
##             depth_particles     #252   +/-   ##
==================================================
  Coverage                   ?   54.02%           
==================================================
  Files                      ?      143           
  Lines                      ?    13917           
  Branches                   ?        0           
==================================================
  Hits                       ?     7518           
  Misses                     ?     6399           
  Partials                   ?        0           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 733bc91...4108632. Read the comment docs.

Copy link
Contributor

@adlarkin adlarkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a lot of comments that are similar to #251. I tested the example world, and it worked for me. My level of understanding of this PR is similar to the level of understanding for #251, so it might be worth having someone else review this if they're reviewing #251 as well.

ogre2/src/Ogre2GpuRays.cc Show resolved Hide resolved
ogre2/src/Ogre2GpuRays.cc Show resolved Hide resolved
ogre2/src/Ogre2GpuRays.cc Outdated Show resolved Hide resolved
test/integration/gpu_rays.cc Outdated Show resolved Hide resolved
test/integration/gpu_rays.cc Outdated Show resolved Hide resolved
test/integration/gpu_rays.cc Outdated Show resolved Hide resolved
test/integration/gpu_rays.cc Outdated Show resolved Hide resolved
test/integration/gpu_rays.cc Show resolved Hide resolved
Signed-off-by: Ian Chen <[email protected]>
Copy link
Contributor

@adlarkin adlarkin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I mentioned before, my understanding of what's going on here isn't perfect, so if someone else wants to take a look as well, go for it, but this looks good to me.

@adlarkin adlarkin merged commit 3f71f83 into depth_particles Feb 17, 2021
@adlarkin adlarkin deleted the lidar_particles branch February 17, 2021 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants