-
Notifications
You must be signed in to change notification settings - Fork 26
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
Perpendicular Pattern in calibration and open cv Error #966
Comments
Hello @upaltamentept , Read the documentation and try to follow every step. It sounds to me like a problem with the labelling. Did you confirm that the labels are correct using the dataset playback? |
Please paste text instead of images. Its easier to search and read. Yes, that model is unsupported, but I am not sure that is the problem. Can you paste here a camera_info message? |
Sure, here's the camera_info topic in text of the camera in text:
I was unsure if I could switch from rational polynomial to a pinhole model, this by publishing this topic and changing that distortion model and matrix to the pinhole format, which has less information. Thanks in advance |
To help you further I need you to
Thanks |
Good evening, here's the command and the result that it gives in its entirety, just to have a little ambiguity. If there's need for any other information feel free to express it. Command: roslaunch segunda_estufa collect_data.launch output_folder:=/home/pedro/ros/workspaces/atom/src/data/datasets/estufa_2_8 overwrite:=true bag_rate:=0.5 bag_start:=0 Message:
|
Wait, but there is no error in the paste above? It should abort with the error you mentioned in your first post, right? Also, no need to put all the output, search for the place where the error is and paste only a few lines above |
No, it doesn't abort, simply issues the next warning as ATOM Warn:
The collections seem to work fine for the camera, as shown in the picture above in the first message of this issue. I am able to run everything, even besides this error. However, I still posted it as it might be the reason why the lidar labeling is not working properly and/or the final part the target appears sideways. Just to make sure I'm doing this right, I'm not using the data labeler in the next picture as my supervisor, André Aguiar, said there was no need as there is a "cloud" effect around the pattern. Is that statement correct? There is also and example of one dataset, similar to the others, where I couldn't not run the calibration step after finishing correcting the dataset in the pointcloud part, giving me the next error message :
Don't know if this error as any prior precedent. Thank you in advance |
Is it an error or a warning?
It could be the reason...
Not sure what this means. We do need to have the lidar data correctly annotated. Can you run the dataset_playback and post an image of the annotations of the lidar?
This error occurs when you run which command? |
OK, now I get it. The idea is to move the interactive marker until the yellow spheres are on top of the points that belong to the pattern. André said there is nothing to do because the points are already in the pattern.
The labelling seems fine.
OK, got it. Can you please upload or send to me the corrected dataset. I think the problem may be in the rgb camera model, as you suggested. |
The problem occurs here
And I think that, as you suggested, it has to do with the camera model, because these points are obtained in the projection here: atom/atom_calibration/src/atom_calibration/calibration/objective_function.py Lines 450 to 454 in 8eaf85d
Which come from this projection function: atom/atom_core/src/atom_core/vision.py Lines 33 to 81 in 8eaf85d
So yes, I think it has something to do with the model. |
Ok, so I think I have good news. The distortion_model is defined in the camera info messages https://docs.ros.org/en/melodic/api/sensor_msgs/html/msg/CameraInfo.html and there are only two types of distortion. Here's how in opencv we use the plumb_bob distortion model. And here's how to implement the rational_polynomial distortion model. So this function only tackles the plum_bob, but I think I can change it to accommodate the rational_polynomial model as well. I will try to make the adaptation in this branch https://github.com/lardemua/atom/tree/rational_polynomial_distortion_model |
This format is not really helpful. Look at my camera_info message post:
Looks better right? The easier it is for me to read your posts, the better I can help you. |
Well I am not really sure how to advance because I cannot find anywhere on the documentation how the distortion parameters are organized in the distortion vector. Here: https://docs.ros.org/en/api/sensor_msgs/html/msg/CameraInfo.html we get this comment:
but for the rational_polynomial I do not know how the parameters are arranged. |
Hi there. Just commited a change to support the rational_polynomial model. Can you try it and see if it works? Don't forget to use the correct branch. |
Hello, many updates, so i'll try to reply to all of them
Sure, here is the dataset and the calibration package "estufa2_9" is the dataset and "segunda_estufa" is the calibration package About the model conversion, what changes did you make? I was experimenting other calibration algorithms and they all have the same problem with the distortion mode, which led to me maybe changing the model within the message itself. That way, I would need to transform those values into the plumb_bob, which it seems that it's just omitting the last values? Not sure about it, so asking for the confirmation.
Will download and try it, will get back at you |
Ok, i created a new workspace to host the new branch, as it was conflicting with the previous one. When i was running this command It gave me this error repeatedly
|
but why are you collecting data again? You should run the same calibrate command as before. |
I was collecting data again due to that step being the one that first flagged the distortion model error. I will then proceed to do the calibration only. Still, it gives that error |
The same error? And is there a print just before? What does this instruction print
|
I meant this error, I understand that it was not to collect data again but the error still happens in case someone wants to try this branch from scratch.
The comment I had made did not go trough idk why. Here's what sit aid when running the calibration command
I'm not understanding why it is not recognizing the 8 distortion parameters |
I agree we have to solve this as well, but its another issue and I think we should focus on the other first.
your camera info has a D with a list of 8 params. I have to try to run this on my side, but that will take a while longer. I will to do it by the end of the week, |
Just found the problem with the 8 parameters. Can you try again please? |
Gives this error this time:
|
Not an update, but I was trying to run a calibration again and caught this next error
I saw this error happened in the issue #850, not sure if there's a fix, as it's somewhat critical due to being on the final step and crashing. The command I'm running is the next one :
|
Good afterrnoon.
I was using the ATOM for a project involving a camera(OAKD) and a single LiDAR(Livox) calibration and, after running the calibration command, it would give me very high result values for the camera, to which the rviz looks like this:
After suggestion of the professor, I changed the tf's in both the urdf.xacro and then in the set_initial_estimate, and after confirming that they were correct, and calibrating, it would give this error:
For an aditional comment, when examining the labeling in the dataset_playback phase, the labeling would always be very wrong, in the likes of the next photo, which lead to me having to correct the entire dataset 1 by 1:
Wondering if I could get some help debugging these errors, been a long time trying to figure out how to fix them. Thanks in advance!
The text was updated successfully, but these errors were encountered: