def test_align_poses_sim3_ignore_missing(self):
    'Consider a simple cases with 4 poses in a line. Suppose SfM only recovers 2 of the 4 poses.'
    wT0 = Pose3(Rot3(np.eye(3)), np.zeros(3))
    wT1 = Pose3(Rot3(np.eye(3)), np.ones(3))
    wT2 = Pose3(Rot3(np.eye(3)), (np.ones(3) * 2))
    wT3 = Pose3(Rot3(np.eye(3)), (np.ones(3) * 3))
    aTi_list = [wT0, wT1, wT2, wT3]
    bTi_list = [None, wT1, None, wT3]
    aTi_list_ = geometry_comparisons.align_poses_sim3_ignore_missing(aTi_list, bTi_list)
    assert (aTi_list_[0] is None)
    assert (aTi_list_[2] is None)
    self.__assert_equality_on_pose3s(computed=[aTi_list_[1], aTi_list_[3]], expected=[aTi_list[1], aTi_list[3]])
Consider a simple cases with 4 poses in a line. Suppose SfM only recovers 2 of the 4 poses.
def test_align_poses_sim3_ignore_missing(self):
    
    wT0 = Pose3(Rot3(np.eye(3)), np.zeros(3))
    wT1 = Pose3(Rot3(np.eye(3)), np.ones(3))
    wT2 = Pose3(Rot3(np.eye(3)), (np.ones(3) * 2))
    wT3 = Pose3(Rot3(np.eye(3)), (np.ones(3) * 3))
    aTi_list = [wT0, wT1, wT2, wT3]
    bTi_list = [None, wT1, None, wT3]
    aTi_list_ = geometry_comparisons.align_poses_sim3_ignore_missing(aTi_list, bTi_list)
    assert (aTi_list_[0] is None)
    assert (aTi_list_[2] is None)
    self.__assert_equality_on_pose3s(computed=[aTi_list_[1], aTi_list_[3]], expected=[aTi_list[1], aTi_list[3]])