Closed zexinyang closed 1 year ago
@zexinyang thanks so much for the review, and for looking into this! I have mostly completed all components of the review and should be submitting my response shortly.
For the errors here, I tried to re-create the errors and couldn't. In the end, it looks like you might have an old version of pycpd installed because the lines of code that have an error don't match the current code. Specifically, there should be an additional if/else statement in the def transform_point_cloud
function that tests if you are trying to transform a low-rank version or not.
Could you try re-pulling, installing, and then running the examples/tests?
# activate your environment
cd /home/geo3d/Zexin/project/pycpd
git pull origin master
pip install .
make dev # optionally install pytest using make dev if you haven't already.
make test # run the tests.
python examples/fish_deformable_3D_register_with_subset_of_points.py
@gattia Thank you for addressing the issue. Now it works perfectly ;)
Hi @gattia and @siavashk,
This is part of the JOSS review process. I found two minor issues after testing your PyCPD package. Could you please address them?
python examples/fish_deformable_3D_register_with_subset_of_points.py
:This error also failed the
pytest
:testing/affine_test.py .. [ 28%] testing/deformable_test.py ..F [ 71%] testing/rigid_test.py .. [100%]
=================================== FAILURES =================================== ___ test_3D_low_rank ___
testing/deformable_test.py:56:
self = <pycpd.deformable_registration.DeformableRegistration object at 0x7f5ff28b62b0> Y = array([[-0.28181282, -0.79432332, 1. ], [-0.37639549, -0.58040108, 1. ], [-0.91641226, ...1006222, 1. ], [-0.10490431, -0.60374743, 1. ], [-0.50945755, 0.00261754, 1. ]])
../../../miniconda3/envs/joss-pycpd/lib/python3.8/site-packages/pycpd/deformable_registration.py:68: ValueError =========================== short test summary info ============================ FAILED testing/deformable_test.py::test_3D_low_rank - ValueError: operands co... ========================= 1 failed, 6 passed in 0.43s ==========================
/home/geo3d/Zexin/project/pycpd/pycpd/rigid_registration.py:45: SyntaxWarning: "is not" with a literal. Did you mean "!="? if R is not None and (R.ndim is not 2 or R.shape[0] is not self.D or R.shape[1] is not self.D or not is_positive_semi_definite(R)): /home/geo3d/Zexin/project/pycpd/pycpd/rigid_registration.py:49: SyntaxWarning: "is not" with a literal. Did you mean "!="? if t is not None and (t.ndim is not 2 or t.shape[0] is not 1 or t.shape[1] is not self.D): /home/geo3d/Zexin/project/pycpd/pycpd/rigid_registration.py:49: SyntaxWarning: "is not" with a literal. Did you mean "!="? if t is not None and (t.ndim is not 2 or t.shape[0] is not 1 or t.shape[1] is not self.D): /home/geo3d/Zexin/project/pycpd/pycpd/affine_registration.py:30: SyntaxWarning: "is not" with a literal. Did you mean "!="? if B is not None and (B.ndim is not 2 or B.shape[0] is not self.D or B.shape[1] is not self.D or not is_positive_semi_definite(B)): /home/geo3d/Zexin/project/pycpd/pycpd/affine_registration.py:34: SyntaxWarning: "is not" with a literal. Did you mean "!="? if t is not None and (t.ndim is not 2 or t.shape[0] is not 1 or t.shape[1] is not self.D): /home/geo3d/Zexin/project/pycpd/pycpd/affine_registration.py:34: SyntaxWarning: "is not" with a literal. Did you mean "!="? if t is not None and (t.ndim is not 2 or t.shape[0] is not 1 or t.shape[1] is not self.D):