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

Added generator for downsampled LIDAR #45

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

guivenca
Copy link

@guivenca guivenca commented Sep 1, 2020

Adapted the original code used for the paper into the current repository structure after some cleanup and reorganization, while preserving mathematical operations.

The main new functionalities are in the folder "reduce", so there shouldn't be any breaking changes. You can create the downsampled LIDAR images via the command "python reduce/generate.py" after re-downloading the dataset (as more information is saved). For each velodyne bin file, it tries to generate downsampled LIDAR images based on the full resolution one, thus in timestamps when that information is not available (e.g. the first 5 or so timestamps) the process skips to the next file with the message "skip: no d". A single calibration file is used in line with the rest of the code

For documentation purposes, let me describe the procedure. The identification of lines is done based on the raw velodyne file, as lines are stored sequentially. After discarding some of the lines based on the donwsampling factor, the measurements are projected into the camera frame. As the exact code used by the dataset authors is not available, some small discrepancies would occur and thus the codes uses values from the corresponding pixel (or one very close to it) of the original LIDAR image

Since it was necessary to modify the download scripts, I took the liberty of merging them into a single file in order avoid repeated code. Now, the letter "t" identifies sequences used for "training", while "v" is used for "validation". Two new folders are kept: "data_oxts" and "data_velo"

An additional dependency is introduced as Pykitti is used to read some of the files. As a side note, it seems that OpenCV is listed as an optional dependency, but it's imported as part of dataloader/kitti_dataloader.py

I've tested it on Windows with Cygwin and Python 3.8.3 for a few sequences. Would appreciate feedback from other situations.

If the changes are approved, it would be reasonable to update the README file too

The two download scripts were combined into a single file in order to
remove repeated code. Both oxts and velodyne data are now kept in
preparation for future features
Based on the original code used for the paper with some minor changes
to fit the new structure and other superficial improvements
@fangchangma
Copy link
Owner

Thanks @guivenca ! The MR looks great to me, except for two minor comments:

  1. The name "reduce" is a bit vague - can we change it to something along the line of "lidar_downsampling" to make it more explicit?
  2. Can we add a README file under the new folder to include your instructions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants