naver / kapture-localization

Provide mapping and localization pipelines based on kapture format
BSD 3-Clause "New" or "Revised" License
268 stars 42 forks source link

Tutorial error #9

Closed charlesyuJY closed 3 years ago

charlesyuJY commented 3 years ago

Hi, I am trying out the Kapture-localization tutorial on google Colab. However, I keep getting errors shown below. Any idea why this is happening? image

yocabon commented 3 years ago

the error you get is

sensors_in_path = path.join(source_path, 'sensors')
assert path.exists(sensors_in_path)

which means it couldn't find the sensors folder inside your input, which also means it's not a valid kapture. Looking at your call, I guess you wrote /mapping when you wanted to write ./mapping (same for others, I don't think the mapping folder is at the root of your filesystem), right ?

charlesyuJY commented 3 years ago

Thank you for the update! I then ran into another issue as shown below. I m currently using python3.7.10 which satisfies the requirement of kapture-localisation. However, this error occurs because the required python version for dataclasses is >=3.6 and <3.7. image

yocabon commented 3 years ago

the dataclasses dependency is here for backward compatibility with python3.6. As far as I understand it's built-in for python3.7 and above. What happens if you removed the installed package ? : run pip uninstall dataclasses -y

charlesyuJY commented 3 years ago

Hi, After updating some of the out-of-date libraries, I managed to resolve this issue. Thank you so much! However, another issue occurred as shown below. I am sorry for spamming you. I starts to get this error about two weeks ago, and I still can't resolve it. I thought this problem occurs due to the fact that my desktop doesnt have GPU for cuda. And I am trying it again on colab with cuda, I still get this issue. Just wondering if you encountered anything like this before? Thank you so much for helping. image

yocabon commented 3 years ago

It says the command 'colmap point_triangulator [...]' failed. The mapping pipeline require colmap version >=3.6 installed on the system and it might not be the case for you, or your installed isn't working as expected ?

first I would make sure that you can run colmap point_triangulator --help just fine, and that the version it writes is correct.

next I would try to run the command manually to see what's going on.

colmap point_triangulator --database_path ./colmap-sfm/r2d2_500/AP-GeM-LM18_top5/colmap.db --image_path colmap-sfm/r2d2_500/AP-GeM-LM18_top5/kapture_inputs/proxy_mapping_gv/sensors/records_data --input_path ./colmap-sfm/r2d2_500/AP-GeM-LM18_top5/priors_for_reconstruction --output_path ./colmap-sfm/r2d2_500/AP-GeM-LM18_top5/reconstruction --Mapper.ba_refine_focal_length 0 --Mapper.ba_refine_principal_point 0 --Mapper.ba_refine_extra_params 0

also make sure to run the python script with -v debug to get as much details as possible before it fails.

charlesyuJY commented 3 years ago

Thank you, the issue is solved by updating Colmap to 3.7. Thank you so much for your help!