forgot an os.listdir -> could not find calib when run from trial + version update
This commit is contained in:
parent
aaa56985e1
commit
9a60007a5a
@ -53,7 +53,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = "0.4"
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -46,7 +46,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.8'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -27,7 +27,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2023, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -41,7 +41,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2023, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -31,7 +31,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -3,5 +3,5 @@
|
||||
|
||||
import sys
|
||||
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
VERSION = __version__
|
@ -28,7 +28,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -32,7 +32,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -37,7 +37,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -31,7 +31,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -29,7 +29,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -31,7 +31,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -31,7 +31,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -37,7 +37,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -35,7 +35,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -27,7 +27,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -31,7 +31,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2022, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -27,7 +27,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -48,7 +48,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -44,7 +44,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.7.2'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -35,7 +35,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = "0.4"
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -51,7 +51,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -36,7 +36,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -27,7 +27,7 @@ __author__ = "HunMin Kim, David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["HuMin Kim, David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.8'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -4,7 +4,7 @@
|
||||
import sys
|
||||
|
||||
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
VERSION = __version__
|
||||
|
||||
|
||||
@ -13,7 +13,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
@ -57,7 +57,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = "0.4"
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
@ -602,6 +602,7 @@ def calibrate_intrinsics(calib_dir, intrinsics_config_dict):
|
||||
|
||||
# calculate intrinsics
|
||||
img = cv2.imread(str(img_path))
|
||||
objpoints = np.array(objpoints)
|
||||
ret_cam, mtx, dist, rvecs, tvecs = cv2.calibrateCamera(objpoints, imgpoints, img.shape[1::-1],
|
||||
None, None, flags=(cv2.CALIB_FIX_K3 + cv2.CALIB_FIX_PRINCIPAL_POINT))
|
||||
h, w = [np.float32(i) for i in img.shape[:-1]]
|
||||
|
@ -34,7 +34,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Maya-Mocap"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -44,7 +44,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -38,7 +38,7 @@ __author__ = "Antoine Falisse, adapted by HunMin Kim"
|
||||
__copyright__ = "Copyright 2022, OpenCap"
|
||||
__credits__ = ["Antoine Falisse", "HunMin Kim"]
|
||||
__license__ = "Apache-2.0 License"
|
||||
__version__ = '0.5'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -54,7 +54,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
@ -560,7 +560,7 @@ def recap_tracking(config, error=0, nb_cams_excluded=0):
|
||||
# if batch
|
||||
session_dir = os.path.realpath(os.path.join(project_dir, '..', '..'))
|
||||
# if single trial
|
||||
session_dir = os.getcwd() if not 'Config.toml' in session_dir else session_dir
|
||||
session_dir = session_dir if 'Config.toml' in os.listdir(session_dir) else os.getcwd()
|
||||
multi_person = config.get('project').get('multi_person')
|
||||
likelihood_threshold_association = config.get('personAssociation').get('likelihood_threshold_association')
|
||||
tracked_keypoint = config.get('personAssociation').get('single_person').get('tracked_keypoint')
|
||||
@ -622,7 +622,7 @@ def track_2d_all(config):
|
||||
# if batch
|
||||
session_dir = os.path.realpath(os.path.join(project_dir, '..', '..'))
|
||||
# if single trial
|
||||
session_dir = os.getcwd() if not 'Config.toml' in session_dir else session_dir
|
||||
session_dir = session_dir if 'Config.toml' in os.listdir(session_dir) else os.getcwd()
|
||||
multi_person = config.get('project').get('multi_person')
|
||||
pose_model = config.get('pose').get('pose_model')
|
||||
tracked_keypoint = config.get('personAssociation').get('single_person').get('tracked_keypoint')
|
||||
|
@ -31,7 +31,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -53,7 +53,7 @@ __author__ = "David Pagnon, HunMin Kim"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.8'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
|
@ -59,7 +59,7 @@ __author__ = "David Pagnon"
|
||||
__copyright__ = "Copyright 2021, Pose2Sim"
|
||||
__credits__ = ["David Pagnon"]
|
||||
__license__ = "BSD 3-Clause License"
|
||||
__version__ = '0.6'
|
||||
__version__ = "0.8.2"
|
||||
__maintainer__ = "David Pagnon"
|
||||
__email__ = "contact@david-pagnon.com"
|
||||
__status__ = "Development"
|
||||
@ -311,7 +311,7 @@ def recap_triangulate(config, error, nb_cams_excluded, keypoints_names, cam_excl
|
||||
# if batch
|
||||
session_dir = os.path.realpath(os.path.join(project_dir, '..', '..'))
|
||||
# if single trial
|
||||
session_dir = os.getcwd() if not 'Config.toml' in os.listdir(session_dir) else session_dir
|
||||
session_dir = session_dir if 'Config.toml' in os.listdir(session_dir) else os.getcwd()
|
||||
calib_dir = [os.path.join(session_dir, c) for c in os.listdir(session_dir) if 'calib' in c.lower()][0]
|
||||
calib_file = glob.glob(os.path.join(calib_dir, '*.toml'))[0] # lastly created calibration file
|
||||
calib = toml.load(calib_file)
|
||||
@ -696,7 +696,7 @@ def triangulate_all(config):
|
||||
# if batch
|
||||
session_dir = os.path.realpath(os.path.join(project_dir, '..', '..'))
|
||||
# if single trial
|
||||
session_dir = os.getcwd() if not 'Config.toml' in os.listdir(session_dir) else session_dir
|
||||
session_dir = session_dir if 'Config.toml' in os.listdir(session_dir) else os.getcwd()
|
||||
multi_person = config.get('project').get('multi_person')
|
||||
pose_model = config.get('pose').get('pose_model')
|
||||
frame_range = config.get('project').get('frame_range')
|
||||
|
Loading…
Reference in New Issue
Block a user