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

Loading Image list error: cap_gstreamer.cpp (873), (616) & cap.cpp (164) & cap_images.cpp (253) #22481

Open
JPark-91 opened this issue Sep 7, 2022 · 1 comment
Labels
question (invalid tracker) ask questions and other "no action" items here: https://forum.opencv.org

Comments

@JPark-91
Copy link

JPark-91 commented Sep 7, 2022

Hi, all

I am using OpenCV 4.5.4 version on Ubuntu 22.04.
This is my first time, so I am trying to practice the opencv by following this website:
https://docs.opencv.org/4.5.0/d4/d94/tutorial_camera_calibration.html

This example is about how to do camera calibration using XML ( I can tell )
So I copied camera_calibration.cpp file from https://github.com/opencv/opencv/blob/master/samples/cpp/tutorial_code/calib3d/camera_calibration/camera_calibration.cpp

I tried to use XML files, so
https://github.com/opencv/opencv/blob/master/samples/cpp/tutorial_code/calib3d/camera_calibration/in_VID5.xml
https://github.com/opencv/opencv/blob/master/samples/cpp/tutorial_code/calib3d/camera_calibration/VID5.xml

I guess my error is coming from here:
I am not sure how to put the right path in my case.
image

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

From here, this is my working environment

image

@catree
Copy link
Contributor

catree commented Sep 7, 2022

I don't have experience with the calibration tutorial code, but with the sample code: https://github.com/opencv/opencv/blob/4.x/samples/cpp/calibration.cpp

If you want to try it, here some instructions.


Build the OpenCV examples:

  • use ccmake (to install use: cmake-curses-gui) to enable the build of the examples
  • switch to ON the BUILD_EXAMPLES variable
  • press c to configure
  • press g to generate
  • make -j8

Create the image list:

  • in the OpenCV build folder, run ./example_cpp_imagelist_creator imagelist_opencv_left.yaml <path to>/opencv/samples/data/left*.jpg
  • remove the left.jpg line since it is not a calibration image

Run the calibration:

  • ./example_cpp_calibration --help for the help
  • ./example_cpp_calibration -w=9 -h=6 -pt=chessboard -s=0.25 -o=opencv_left.xml imagelist_opencv_left.yaml
  • read the code to understand the meaning of each parameter
  • experiment with the other parameters

You should get your calibration file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question (invalid tracker) ask questions and other "no action" items here: https://forum.opencv.org
Projects
None yet
Development

No branches or pull requests

3 participants