Skip to content

Free Motion Capture for Everyone πŸ’€βœ¨

TypeScript

more or less works :D

Jonb526ff379c48
diff --git a/jon_scratch/pupil_calibration_pipeline/pupil_freemocap_calibration_pipeline_orchestrator.py b/jon_scratch/pupil_calibration_pipeline/pupil_freemocap_calibration_pipeline_orchestrator.py
index 0148ce5b..61847733 100644
--- a/jon_scratch/pupil_calibration_pipeline/pupil_freemocap_calibration_pipeline_orchestrator.py
+++ b/jon_scratch/pupil_calibration_pipeline/pupil_freemocap_calibration_pipeline_orchestrator.py
@@ -92,7 +92,7 @@ class PupilFreemocapCalibrationPipelineOrchestrator:
vor_calibrator = VorCalibrator(synchronized_session_data.mediapipe_skel_fr_mar_dim.copy(),
vor_start_frame=self.vor_frame_start,
vor_end_frame=self.vor_frame_end,
- debug=True)
+ debug=False)
right_index_fingertip_idx = 41 # pretty sure this is right?
fixation_point_fr_xyz = synchronized_session_data.mediapipe_skel_fr_mar_dim[
self.vor_frame_start:self.vor_frame_end,
@@ -116,9 +116,9 @@ class PupilFreemocapCalibrationPipelineOrchestrator:
####
qt_gl_laser_skeleton = QtGlLaserSkeletonVisualizer(session_data=synchronized_session_data,
- move_data_to_origin=True,
- start_frame=self.vor_frame_start,
- end_frame=self.vor_frame_end)
+ move_data_to_origin=True,)
+ # start_frame=self.vor_frame_start,
+ # end_frame=self.vor_frame_end)
qt_gl_laser_skeleton.start_animation()
diff --git a/jon_scratch/pupil_calibration_pipeline/vor_calibrator.py b/jon_scratch/pupil_calibration_pipeline/vor_calibrator.py
index 22f227f5..f9d4c71e 100644
--- a/jon_scratch/pupil_calibration_pipeline/vor_calibrator.py
+++ b/jon_scratch/pupil_calibration_pipeline/vor_calibrator.py
@@ -120,7 +120,8 @@ class VorCalibrator:
args=(eye_socket_origin_fr_xyz[vor_frames, :],
eye_socket_rotation_matricies[
self.vor_start_frame:self.vor_end_frame],
- head_rotation_matricies,
+ head_rotation_matricies[
+ self.vor_start_frame:self.vor_end_frame],
fixation_point_fr_xyz,
gaze_x[vor_frames],
gaze_y[vor_frames],
@@ -266,7 +267,7 @@ class VorCalibrator:
# THEN rotate gaze vector by eye_socket_rotation_matrix to align it with the eye sockets gaze direction (i think)
gaze_fr_xyz = [
- np.transpose(eye_socket_rotation_matricies[this_frame_number]) @ gaze_rotated_by_guess_fr_xyz[
+ np.transpose(head_rotation_matricies[this_frame_number]) @ gaze_rotated_by_guess_fr_xyz[
this_frame_number, :] for
this_frame_number in
range(gaze_rotated_by_guess_fr_xyz.shape[0])]