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

Image gaps while LidarScan from LidarPackets #259

Open
rmbsmit opened this issue Nov 16, 2023 · 5 comments
Open

Image gaps while LidarScan from LidarPackets #259

rmbsmit opened this issue Nov 16, 2023 · 5 comments
Assignees
Labels
question Further information is requested

Comments

@rmbsmit
Copy link

rmbsmit commented Nov 16, 2023

Describe your question
I have recorded a bagfile containing LidarPackets (type PacketMsg.msg). From this data, i am trying to batch them, recreate a LidanScan using the ScanBatcher and view the Intensity/Reflectivy/Range images in python. However, when looking at the final images, there seems to be a problem in either the batching of the LidarPackets, or in the destaggering. The Range output image looks like this:

25

The image itself seems fine, however there are gaps in between the packages.

The sample code look like this:

        self.batcher = client._client.ScanBatcher(self.metadata)
        self.ls = client.LidarScan(height,
                          width,
                          self.metadata.format.udp_profile_lidar)

def Callback(self, msg):
packet = client.LidarPacket(msg.buf, self.metadata, _raise_on_id_check=True)
if self.batcher(packet, self.ls):
            ref_field = self.ls.field(client.ChanField.SIGNAL)
            ref_val = client.destagger(self.metadata, ref_field, inverse=False)
            ref_img = (ref_val / np.max(ref_val) * 255).astype(np.uint8)

The metadata comes from the .json file from the same recording

Platform (please complete the following information):

  • Ouster OS2
  • ROS version: noetic
  • Operating System: Ubuntu 20.04

Can somebody help me solve the issue?

@rmbsmit rmbsmit added the question Further information is requested label Nov 16, 2023
@Samahu
Copy link
Contributor

Samahu commented Nov 16, 2023

Do you get the same gaps when replaying the bagfile through the driver?

@Samahu Samahu self-assigned this Nov 16, 2023
@rmbsmit
Copy link
Author

rmbsmit commented Nov 17, 2023

No, replaying the bagfile, the images look fine.

Screenshot from 2023-11-17 09-56-16

@rmbsmit
Copy link
Author

rmbsmit commented Dec 4, 2023

@Samahu do you have any update on this issue? Thanks in advance

@Samahu
Copy link
Contributor

Samahu commented Dec 4, 2023

I don't have an update but looking briefly at your code I am wondering if you actually filter out ImuPacket before trying to parse the packet as a LidarPacket.

@bexcite

This comment was marked as off-topic.

tobii-ho pushed a commit to StarkStrom-Driverless/ouster-ros that referenced this issue Dec 27, 2023
* Add support for the new signal_multiplier config parameter
* Add support for the new 8-bit reflectivity format in simple_viz
* Update Python ouster-sdk package to version 0.2.1, bugfix release
* Remove viz_node and graphics packages from ROS build dependencies
* Ensure ouster_ros dependencies can be satisfied using rosdep
* Various improvements to the ROS img node output
tobii-ho pushed a commit to StarkStrom-Driverless/ouster-ros that referenced this issue Jan 23, 2024
…r#259)

* Add support for the new signal_multiplier config parameter
* Add support for the new 8-bit reflectivity format in simple_viz
* Update Python ouster-sdk package to version 0.2.1, bugfix release
* Remove viz_node and graphics packages from ROS build dependencies
* Ensure ouster_ros dependencies can be satisfied using rosdep
* Various improvements to the ROS img node output
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants