My camera calibration matrices and distortion matrices derived from aruco_calibration_fromimages.exe :
[[3.19439125e+03 0.00000000e+00 1.98509417e+03]
[0.00000000e+00 3.20213561e+03 1.55099552e+03]
[0.00000000e+00 0.00000000e+00 1.00000000e+00]]
[[0.1395281 -0.38313647 0.00505558 0.00237535 0.33952515]]
Image where I am trying to detect:

aruco_simple.exe successfully

But python code does not find anything:
fs = cv2.FileStorage("./calib_asus_chess/cam_calib_asus.yml", cv2.FILE_STORAGE_READ)
cam_mat=fs.getNode("camera_matrix").mat()
dist_mat=fs.getNode("distortion_coefficients").mat()
gray=cv2.imread('C:\\Users\\steve\\Dropbox\\Projects\\kinnekt\\laser\\aruco_frames\\shot1.jpg',0)
adict = cv2.aruco.Dictionary_get(cv2.aruco.DICT_ARUCO_ORIGINAL)
res = cv2.aruco.detectMarkers(gray,dictionary=adict,cameraMatrix=cam_mat,distCoeff=dist_mat)
res [0] is for some reason an empty array. Why is python version not working? Thanx!
source
share