CMU-Perceptual-Computing-Lab / openpose

OpenPose: Real-time multi-person keypoint detection library for body, face, hands, and foot estimation
https://cmu-perceptual-computing-lab.github.io/openpose
Other
30.67k stars 7.82k forks source link

Wrong Chessboard Detection Results #2052

Open wanggao1990 opened 2 years ago

wanggao1990 commented 2 years ago

The size of chessboard inner corner is 7x6,grid square size 120mm,

When using the Calibration Module to computes and saves intrinsics parameters of the input images, the grid inner corners' detection results was not stable. The first corner location should be TopLetf, but somehow is TopRight.

Calibration.exe 
 -mode                      1 
-grid_square_size_mm        120.0
-grid_number_inner_corners  7x6
-camera_serial_number       ipc1
-calibration_image_dir         path_imgs/
-camera_parameter_folder  path_imgs/

The snapshot of calibration output result in images_with_corners dir:

image

wanggao1990 commented 2 years ago

Test imgs download link: test_imgs.zip

gineshidalgo99 commented 2 years ago

Unfortunately, the detection of corners is based on heuristics because it is very hard to properly detect from an image which corner is the "top-right" corner without other marks on the chessboard.

What I end up doing is detecting a lot of images, so that the outliers are a minority and it does not affect the overall result. The code is ready to ignore outliers, but the number of images where the chessboard is properly detected has to be high enough, meaning >50-100 depending on the quality of the images (are there images of different scales of the chessboard, different positions of the image (not only the center), etc. I hope this tip helps!

wanggao1990 commented 2 years ago

The checkerboard detection strategy is acceptable in the calibration of intrinsics parameters. When come to the extrinsics parameters calibratation, the order error of detected checkerboard corners from different camera views will lead to calculation errors. In such case, can enough image data also overcome this problem?

gineshidalgo99 commented 2 years ago

Yes because I added a basic kind-of-ransac approach to clean noisy detections (i.e., mostly the ones with the wrong order of frames). So with enough frames, it usually gives pretty good results (at least in my personal 3- and 4-camera setups)