3DOM-FBK / deep-image-matching

Multiview matching with deep-learning and hand-crafted local features for COLMAP and other SfM software. Supports high-resolution formats and images with rotations. Both CLI and GUI are supported.
https://3dom-fbk.github.io/deep-image-matching/
BSD 3-Clause "New" or "Revised" License
294 stars 31 forks source link

Switching from SIMPLE_RADIAL to PINHOLE Camera Model Causes AttributeError in pycolmap #46

Closed helloycr closed 3 months ago

helloycr commented 4 months ago

thank you very much

lcmrl commented 4 months ago

Hi, thanks for the feedback. Do you still have the problem? Probably is related to the new version of pycolmap. Please, change in src/deep_image_matching/reconstruction.py the following:

     for camera_id, cam in enumerate(cameras, start=1):
         db.update_camera(
-            camera_id, cam.model_id, cam.width, cam.height, cam.params, True
+            camera_id, cam.model.value, cam.width, cam.height, cam.params, True
         )
     db.commit()
     db.close()

this should do the work. Let me know if you still encounter the issue

lcmrl commented 3 months ago

Hi, I have added this change in dev branch, soon we will merge to main. Let me know if you face other problems

helloycr commented 3 months ago

i love you

helloycr commented 3 months ago

i love you too

lcmrl commented 3 months ago

Are you using the last version of pycolmap? On windows or linux?

helloycr commented 3 months ago

love you

lcmrl commented 3 months ago

and pycolmap 0.6.1?

helloycr commented 3 months ago

love you

lcmrl commented 3 months ago

Could you try to uninstall pycolmap and reinstall it so that it will be the last one 0.6.1? This should do the trick