-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
[io] savePCDFileBinaryCompressed pcd file can't open with coredump error #4958
Comments
BTW: starting with PCL 1.9.0, you get a nice error message instead of just a coredump when trying to read a corrupted file. |
Are you absolutely sure that you use PCL 1.9 to write the files? I found this pull request: #2325 The description there (and in the linked issue) sounds just like what you experience. If possible, please also try if the problem also occurs with PCL 1.12.0. |
for(int i =0; i< 50;i++) {
std::string fileName =
pcd_dir + "/" + std::to_string(timestamp) + "_" + std::to_string(i) + ".pcd";
pcl::io::savePCDFileBinaryCompressed(fileName, *cloud_out);
std::cout << "save frame: " << frameItem << " to pcd: " << fileName
<< std::endl;
} |
I checked the code that writes the binary compressed PCD files, but it looks okay. For every IO operation, there is a check whether the operation succeeded, and it prints an error or throws an exception if it doesn't succeed, but if I understood you correctly, there are no errors while writing the PCD files, right? |
Acctually object storage is prallell operation, we generate it in local file system(docker container) firstly and move it to storage one time way. So I don't think it is an problem of object storage. |
Can you verify then whether there are already bad/corrupted files directly after writing them to the local file system, or whether they only appear after moving them to the external storage? |
thank you so much for you repply!
|
Describe the bug
We use
pcl::io::savePCDFileBinaryCompressed(label_pcd_Name, *cloud_out);
to save our pcd file, and in most situation ,it works well. But in same output file(2 pcd files in 100k), it will meet coredump error likeLoading /mnt/data/Lidar_B3_1632536240.453701.pcd [1] 24581 bus error (core dumped)
, Even though we use different tools.Context
What are you trying to accomplish? Providing context helps us come up with a solution that is most useful in the real world
pcd file header
Although 317,794 point clouds are described in the header, the file size is actually only 2.2M, which is half smaller than the normal 4.5M.
pcl_viewer:
cloudcompare :
gdb meesage :
Expected behavior
A clear and concise description of what you expected to happen.
read pcd and points ok
Current Behavior
What happens instead of the expected behavior?
pcd file can't read with coredump
To Reproduce
Provide a link to a live example, or an unambiguous set of steps to reproduce this bug. A reproducible example helps to provide faster answers.
Screenshots/Code snippets
In order to help explain your problem, please consider adding
Your Environment (please complete the following information):
Possible Solution
Not obligatory, but suggest a fix/reason for the bug. Feel free to create a PR if you feel comfortable.
Additional context
Add any other context about the problem here.
origin pcd file is here
Lidar_B3_1632536240.453701.zip
normal_and_coredump_2pcd.zip
The text was updated successfully, but these errors were encountered: