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

errors when running tutorial #10

Closed tyjiang1997 closed 3 years ago

tyjiang1997 commented 3 years ago

While I was following the tutorial, I made the following error.How should I solve it?thank you INFO ::colmap: ['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'] ERROR: Failed to parse options: unrecognised option '--input_path'. Traceback (most recent call last): File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 270, in <module> colmap_build_map_command_line() File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 266, in colmap_build_map_command_line args.skip, args.force) File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 71, in colmap_build_map force) File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 177, in colmap_build_map_from_loaded_data point_triangulator_options File "/home/jty/.local/lib/python3.6/site-packages/kapture_localization/colmap/colmap_command.py", line 275, in run_point_triangulator run_colmap_command(colmap_binary_path, point_triangulator_args) File "/home/jty/.local/lib/python3.6/site-packages/kapture_localization/colmap/colmap_command.py", line 70, in run_colmap_command '\nSubprocess Error (Return code:' ValueError: Subprocess Error (Return code: 1 ) Traceback (most recent call last): File "/home/jty/.local/bin/kapture_pipeline_mapping.py", line 249, in <module> mapping_pipeline_command_line() File "/home/jty/.local/bin/kapture_pipeline_mapping.py", line 239, in mapping_pipeline_command_line args.force) File "/home/jty/.local/bin/kapture_pipeline_mapping.py", line 150, in mapping_pipeline run_python_command(local_build_map_path, build_map_args, python_binary) File "/home/jty/.local/lib/python3.6/site-packages/kapture_localization/utils/subprocess.py", line 67, in run_python_command raise ValueError('\nSubprocess Error (Return code:' f' {python_process.returncode} )') ValueError: Subprocess Error (Return code: 1 )

yocabon commented 3 years ago

Your version of colmap is probably outdated, you must have colmap 3.6 or more recent. run colmap point_triangulator --help and check that the version it writes is correct. I know that apt-get in Ubuntu 18.04 will install an ancient version of colmap (3.4).

tyjiang1997 commented 3 years ago

Thanks for your reply. I have solved this problem. And I encounter another question when I try to run kapture_datasets/Aachen-Day-Night-v1.1 Dataset: The Aachen-Day-Night-v1.1 can be download successful, but when I run the fellowing commads, the error comes. # this will merge query_day and query_night into query_all kapture_merge.py -v info \ -i query_day query_night \ -o query_all \ --image_transfer link_relative

and the error is : "sensors/records_data" already in "query_all". Delete ? [y/N]y INFO ::merge: Loading query_day INFO ::merge: Loading query_night Traceback (most recent call last): File "/home/jty/.local/bin/kapture_merge.py", line 146, in <module> merge_command_line() File "/home/jty/.local/bin/kapture_merge.py", line 142, in merge_command_line merge_kaptures(args.inputs, args.output, args.keep_sensor_ids, args.image_transfer, args.skip, args.force) File "/home/jty/.local/bin/kapture_merge.py", line 96, in merge_kaptures merged_path, images_import_strategy) File "/home/jty/.local/lib/python3.6/site-packages/kapture/algo/merge_remap.py", line 455, in merge_remap new_matches = merge_matches_collections(matches, data_paths, kapture_path, tarcollection_list) File "/home/jty/.local/lib/python3.6/site-packages/kapture/algo/merge_reconstruction.py", line 293, in merge_matches_collections assert len(keypoints_types) > 0 AssertionError

yocabon commented 3 years ago

Definitely a bug. I pushed a fix to kapture. If you don't want to reinstall kapture from source, you can use the option -s matches when running kapture_merge.py to avoid the error.

tyjiang1997 commented 3 years ago

Thank you for your reply again. When i run commad as you say: kapture_merge.py -v info -i query_day query_night -o query_all -s matches --image_transfer link_relative I got another questionas INFO ::merge: Loading query_day Traceback (most recent call last): File "/home/jty/.local/bin/kapture_merge.py", line 146, in <module> merge_command_line() File "/home/jty/.local/bin/kapture_merge.py", line 142, in merge_command_line merge_kaptures(args.inputs, args.output, args.keep_sensor_ids, args.image_transfer, args.skip, args.force) File "/home/jty/.local/bin/kapture_merge.py", line 85, in merge_kaptures kapture_data = kapture_from_dir(kapture_path, tar_handlers=tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1451, in kapture_from_dir raise FileNotFoundError(f'No kapture directory {kapture_dir_path}') FileNotFoundError: No kapture directory query_day Is that mean the dataset is not full?

tyjiang1997 commented 3 years ago

I am sorry. it is my fault

Thank you for your reply again. When i run commad as you say: kapture_merge.py -v info -i query_day query_night -o query_all -s matches --image_transfer link_relative I got another questionas INFO ::merge: Loading query_day Traceback (most recent call last): File "/home/jty/.local/bin/kapture_merge.py", line 146, in <module> merge_command_line() File "/home/jty/.local/bin/kapture_merge.py", line 142, in merge_command_line merge_kaptures(args.inputs, args.output, args.keep_sensor_ids, args.image_transfer, args.skip, args.force) File "/home/jty/.local/bin/kapture_merge.py", line 85, in merge_kaptures kapture_data = kapture_from_dir(kapture_path, tar_handlers=tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1451, in kapture_from_dir raise FileNotFoundError(f'No kapture directory {kapture_dir_path}') FileNotFoundError: No kapture directory query_day Is that mean the dataset is not full? I am sorry. It is mu default

tyjiang1997 commented 3 years ago

I'm sorry to disturb you again. When I run the fellow commad. kapture_pipeline_image_retrieval_benchmark.py -v info \ -i Aachen-Day-Night-v1.1/mapping \ --query Aachen-Day-Night-v1.1/query_all \ -kpt Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/keypoints \ -desc Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/descriptors \ -gfeat Aachen-Day-Night-v1.1/global_features/AP-GeM-LM18/global_features \ -matches Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_no_gv/matches \ -matches-gv Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_colmap_gv/matches \ --colmap-map Aachen-Day-Night-v1.1/colmap-sfm/r2d2_WASF-N8_20k/frustum_thresh10_far50/colmap \ -o Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF-N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20 \ --topk 20 \ --config 2

I encounter this problem: INFO ::compute_image_pairs: compute_image_pairs. loading mapping: /home/jty/vslam/kapture-localization-main/kapture_datasets/Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF_N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20/kapture_inputs/proxy_mapping Traceback (most recent call last): File "/home/jty/.local/bin/kapture_compute_image_pairs.py", line 158, in <module> compute_image_pairs_command_line() File "/home/jty/.local/bin/kapture_compute_image_pairs.py", line 154, in compute_image_pairs_command_line compute_image_pairs(args.mapping, args.query, args.output, args.global_features_type, args.topk) File "/home/jty/.local/bin/kapture_compute_image_pairs.py", line 50, in compute_image_pairs tar_handlers=mapping_tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1503, in kapture_from_dir kapture_loadable_data, kapture_data, tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1681, in _load_features_and_desc_and_matches tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1133, in global_features_from_dir config = global_features_config_from_file(config_filepath) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1106, in global_features_config_from_file assert len(line) == 4

Could you tell me how to solve this, many thanks

tyjiang1997 commented 3 years ago

I'm sorry to disturb you again. When I run the fellow commad. kapture_pipeline_image_retrieval_benchmark.py -v info \ -i Aachen-Day-Night-v1.1/mapping \ --query Aachen-Day-Night-v1.1/query_all \ -kpt Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/keypoints \ -desc Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/descriptors \ -gfeat Aachen-Day-Night-v1.1/global_features/AP-GeM-LM18/global_features \ -matches Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_no_gv/matches \ -matches-gv Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_colmap_gv/matches \ --colmap-map Aachen-Day-Night-v1.1/colmap-sfm/r2d2_WASF-N8_20k/frustum_thresh10_far50/colmap \ -o Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF-N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20 \ --topk 20 \ --config 2

I encounter this problem: INFO ::compute_image_pairs: compute_image_pairs. loading mapping: /home/jty/vslam/kapture-localization-main/kapture_datasets/Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF_N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20/kapture_inputs/proxy_mapping Traceback (most recent call last): File "/home/jty/.local/bin/kapture_compute_image_pairs.py", line 158, in <module> compute_image_pairs_command_line() File "/home/jty/.local/bin/kapture_compute_image_pairs.py", line 154, in compute_image_pairs_command_line compute_image_pairs(args.mapping, args.query, args.output, args.global_features_type, args.topk) File "/home/jty/.local/bin/kapture_compute_image_pairs.py", line 50, in compute_image_pairs tar_handlers=mapping_tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1503, in kapture_from_dir kapture_loadable_data, kapture_data, tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1681, in _load_features_and_desc_and_matches tar_handlers) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1133, in global_features_from_dir config = global_features_config_from_file(config_filepath) File "/home/jty/.local/lib/python3.6/site-packages/kapture/io/csv.py", line 1106, in global_features_config_from_file assert len(line) == 4

Could you tell me how to solve this, many thanks

it sames that this line only contains three items (name, dtype, dsize), and do not contain 'metric_type'

yocabon commented 3 years ago

Hi, we changed the format of the features recently (the .txt and position within reconstruction/ changed in kapture 1.1) but the global features files available with the downloader are still in the 1.0 format (kapture 1.1 is not backward compatible with 1.0). For regular kapture folders, it automatically upgrade them but it didn't upgrade "orphan" features like the one you probably downloaded. I added some code in kapture to accommodate this, which I hope will do the job, but for you it should be very simple to manually upgrade them.

in Aachen-Day-Night-v1.1/global_features/AP-GeM-LM18/global_features/global_features.txt, you should have

# name, dtype, dsize
dirtorch, float32, 2048

change it to

# kapture format: 1.1
# name, dtype, dsize, metric_type
dirtorch, float32, 2048, L2
tyjiang1997 commented 3 years ago

Hi, we changed the format of the features recently (the .txt and position within reconstruction/ changed in kapture 1.1) but the global features files available with the downloader are still in the 1.0 format (kapture 1.1 is not backward compatible with 1.0). For regular kapture folders, it automatically upgrade them but it didn't upgrade "orphan" features like the one you probably downloaded. I added some code in kapture to accommodate this, which I hope will do the job, but for you it should be very simple to manually upgrade them.

in Aachen-Day-Night-v1.1/global_features/AP-GeM-LM18/global_features/global_features.txt, you should have

# name, dtype, dsize
dirtorch, float32, 2048

change it to

# kapture format: 1.1
# name, dtype, dsize, metric_type
dirtorch, float32, 2048, L2

Thank you very much. Do you mean that I can add metric_type = L2 manually

yocabon commented 3 years ago

yes, just edit the txt file by hand.

tyjiang1997 commented 3 years ago

Thank you very much. I'll test that out later. QAQ

yocabon commented 3 years ago

note: if you downloaded the colmap map from our downloader and extracted the r2d2 keypoints/descriptors yourself as written in the documentation, you might still get very bad results. r2d2 extraction doesn't seem to always give the same results for all gpus/machines, and we didn't share our extracted local_features because of size I believe; so you'll probably have to do the mapping part as well. We'll add more precision later.

tyjiang1997 commented 3 years ago

Thank you very, very much. I will add my own data set according to your method later, this project supports this function, right

tyjiang1997 commented 3 years ago

Thank you for all your relaies. Those days I come to xi'an to attend ICRA2021. and after I change your code as with open(config_filepath, 'rt') as file: table = table_from_file(file) line = list(table)[0] assert len(line) <= 3 name, dtype, dsize, metric_type = line[0], line[1], int(line[2]), 'L2' I encounter another question like: INFO ::compute_image_pairs: saving to file ... INFO ::compute_image_pairs: all done INFO ::merge: Loading /home/jty/vslam/kapture-localization-main-v1/kapture_datasets/Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF_N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20/kapture_inputs/proxy_mapping INFO ::merge: Loading /home/jty/vslam/kapture-localization-main-v1/kapture_datasets/Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF_N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20/kapture_inputs/proxy_query INFO ::merge: Writing merged kapture data... INFO ::compute_matches: compute_matches. loading input: /home/jty/vslam/kapture-localization-main-v1/kapture_datasets/Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF_N8_20k/frustum_thresh10_far50/AP-GeM-LM18_top20/kapture_inputs/proxy_map_plus_query INFO ::compute_matches: reading pairs from pairsfile Traceback (most recent call last): File "/home/jty/anaconda3/envs/vslam/bin/kapture_compute_matches.py", line 4, in <module> __import__('pkg_resources').run_script('kapture-localization==0.0.4', 'kapture_compute_matches.py') File "/home/jty/anaconda3/envs/vslam/lib/python3.7/site-packages/pkg_resources/__init__.py", line 651, in run_script self.require(requires)[0].run_script(script_name, ns) File "/home/jty/anaconda3/envs/vslam/lib/python3.7/site-packages/pkg_resources/__init__.py", line 1448, in run_script exec(code, namespace, namespace) File "/home/jty/anaconda3/envs/vslam/lib/python3.7/site-packages/kapture_localization-0.0.4-py3.7.egg/EGG-INFO/scripts/kapture_compute_matches.py", line 206, in <module> compute_matches_command_line() File "/home/jty/anaconda3/envs/vslam/lib/python3.7/site-packages/kapture_localization-0.0.4-py3.7.egg/EGG-INFO/scripts/kapture_compute_matches.py", line 202, in compute_matches_command_line args.overwrite) File "/home/jty/anaconda3/envs/vslam/lib/python3.7/site-packages/kapture_localization-0.0.4-py3.7.egg/EGG-INFO/scripts/kapture_compute_matches.py", line 96, in compute_matches overwrite_existing) File "/home/jty/anaconda3/envs/vslam/lib/python3.7/site-packages/kapture_localization-0.0.4-py3.7.egg/EGG-INFO/scripts/kapture_compute_matches.py", line 107, in compute_matches_from_loaded_data assert kdata.descriptors is not None AssertionError Could you help me to slove this? And I see that you have update your code these days, should I download the latest version ?

yocabon commented 3 years ago

Hi, I meant to change the global_features.txt file within the dataset, not the code itself. I think it's related to the other issue, kapture_localization is using version 0.0.4 which is not compatible with the more up to date version of kapture that you are using. We recently changed the kapture format to 1.1, and it's not backward compatible. For now: kapture 1.0.x version goes with kapture-localization 0.0.x kapture 1.1.x version goes with kapture-localization 0.1.x

tyjiang1997 commented 3 years ago
thans. I check my code and find that the version is : kapture 1.1.1 kapture-localization 0.1.2 I think it is right. but I also can not get the right results. And I find that 'descriptor.txt' is not in the right path. so I can not get 'kadate.descripture'. After I change the dictionary: `descriptors ----r2d2_WASF-N8_20k
 ---r2d2_WASF_N8_big
    |
    ----db
    ----query
    ----sequences
    ----descriptors

to descriptors | ----r2d2_WASF-N8_20k ----db ----query ----sequences ----descriptors ` I can get the kadata.descriptor value. But after that I encounter another question as ' (sequences/gopro3_undistorted/gopro3_00188.png , sequences/gopro3_undistorted/gopro3_00663.png), (sequences/gopro3_undistorted/gopro3_00799.png , sequences/gopro3_undistorted/gopro3_00948.png), (sequences/gopro3_undistorted/gopro3_00480.png , sequences/gopro3_undistorted/gopro3_00514.png), (sequences/gopro3_undistorted/gopro3_00915.png , sequences/nexus4_sequences/sequence_7/aachen_nexus4_seq7_0148.png), (db/1855.jpg , db/525.jpg), (db/1439.jpg , db/1561.jpg), (db/1755.jpg , sequences/gopro3_undistorted/gopro3_01005.png), (sequences/gopro3_undistorted/gopro3_00359.png , sequences/gopro3_undistorted/gopro3_00382.png), (sequences/gopro3_undistorted/gopro3_00878.png , sequences/gopro3_undistorted/gopro3_01011.png), (db/732.jpg , sequences/nexus4_sequences/sequence_4/aachen_nexus4_seq4_0333.png) ], 'r2d2_WASF-N8_20k': no matches} has more than 1 item, cannot decide which to pick

yocabon commented 3 years ago

With kapture-1.1, multiple types of keypoints / descriptors / global features can be put in one kapture. Our code don't leverage this so most of the time we only have one. To avoid having to manually put the names of these folders in the command lines, I've put several systems in place. First the "local_features/" and "global_features/" part of the suggested naming is here to help the code find these names and create the correct symlinks. Second, try_get_only_key_from_collection is used when the commands are passed with keypoints-type None (or descriptors-type None or global-features-type None). It assumes that there is only one value to pick from and return it.

In the pipeline scripts, these assumptions should be correct, but perhaps you manually changing names, and perhaps reruning it without removing the output folder entirely created a kapture with the same descriptors listed under different names and the code is confused about it.

let's do it methodically. Use both kapture and kapture-localization from source, latest version, cloned side by side, uninstall the pip versions.

you should have something like that


Aachen-Day-Night-v1.1
├─ mapping
│  └─ sensors
│     ├─ sensors.txt
│     ├─ trajectories.txt  
│     ├─ records_camera.txt 
│     └─ records_data/   
├─ query
│  └─ sensors
│     ├─ sensors.txt  
│     ├─ trajectories.txt 
│     ├─ records_camera.txt
│     └─ records_data/
├─ local_features
│  ├─ r2d2_WASF-N8_20k
│  │  ├─ keypoints/
│  │  │  ├─ db
│  │  │  ├─ keypoints.txt   # "r2d2, float32, 3"
│  │  │  ├─ query
│  │  │  └─ sequences
│  │  ├─ descriptors/
│  │  │  ├─ db
│  │  │  ├─ descriptors.txt     # this one should contain the line "r2d2, float32, 128, r2d2_WASF-N8_20k, L2", name is important
│  │  │  ├─ query
│  │  │  └─ sequences
│  │  ├─ NN_no_gv
│  │  │  └─ matches/ # it will be filled by the scripts
│  │  └─ NN_colmap_gv/ 
│  │     └─ matches/# it will be filled by the scripts
├─ global_features
│  ├─  AP-GeM-LM18
│  │  ├─ global_features
│  │  │  ├─ db
│  │  │  ├─ global_features.txt     # "dirtorch, float32, 2048, L2"
│  │  │  ├─ query
│  │  │  ├─ sequences
└─ pairsfile
   └─ mapping
      └─ Aachen_Day_Night_1_1_ir_benchmark_pairs.txt

Make sure Aachen-Day-Night-v1.1/colmap-sfm/r2d2_WASF-N8_20k/ir_benchmark/colmap is empty or does not exist

kapture_pipeline_mapping.py -v debug \
    -i Aachen-Day-Night-v1.1/mapping \
    -kpt Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/keypoints \
    -desc Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/descriptors \
    --pairsfile-path Aachen-Day-Night-v1.1/pairsfile/mapping/Aachen_Day_Night_1_1_ir_benchmark_pairs.txt \
    -matches Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_no_gv/matches \
    -matches-gv Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_colmap_gv/matches \
    --colmap-map Aachen-Day-Night-v1.1/colmap-sfm/r2d2_WASF-N8_20k/ir_benchmark/colmap

to compute the map, then make sure Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF-N8_20k/ir_benchmark/AP-GeM-LM18_top20 is empty or does not exist and run

kapture_pipeline_image_retrieval_benchmark.py -v debug \
      -i Aachen-Day-Night-v1.1/mapping \
      --query Aachen-Day-Night-v1.1/query_all \
      -kpt Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/keypoints \
      -desc Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/descriptors \
      -gfeat Aachen-Day-Night-v1.1/global_features/AP-GeM-LM18/global_features \
      -matches Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_no_gv/matches \
      -matches-gv Aachen-Day-Night-v1.1/local_features/r2d2_WASF-N8_20k/NN_colmap_gv/matches \
      --colmap-map Aachen-Day-Night-v1.1/colmap-sfm/r2d2_WASF-N8_20k/ir_benchmark/colmap \
      -o Aachen-Day-Night-v1.1/image_retrieval_benchmark/r2d2_WASF-N8_20k/ir_benchmark/AP-GeM-LM18_top20 \
      --topk 20 \
      --config 2

if you still get an error, please attach the full logs.
tyjiang1997 commented 3 years ago

Should I install kapture and kapture-location from source like: `# install developer requirements sudo apt-get install -y git pandoc asciidoctor

clone source repository

git clone https://github.com/naver/kapture-localization.git cd kapture-localization

check everything is fine

python3 -m unittest discover -s tests

install

python3 setup.py build install `

yocabon commented 3 years ago

actually, you don't have to install them. What I do is just

git clone https://github.com/naver/kapture-localization.git
git clone https://github.com/naver/kapture.git

and call the python scripts with their full paths (instead of kapture_pipeline_mapping.py I call kapture-localization/pipeline/kapture_pipeline_mapping.py). I also add the kapture and kapture-localization folders to my PYTHONPATH but that's only necessary if you want to use kapture in your own code.

-- the issue I have with python3 setup.py build install is that there is no easy uninstall equivalent; you have to manually remove the installed files which is annoying

AddASecond commented 3 years ago

While I was following the tutorial, I made the following error.How should I solve it?thank you INFO ::colmap: ['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'] ERROR: Failed to parse options: unrecognised option '--input_path'. Traceback (most recent call last): File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 270, in <module> colmap_build_map_command_line() File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 266, in colmap_build_map_command_line args.skip, args.force) File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 71, in colmap_build_map force) File "/home/jty/.local/bin/kapture_colmap_build_map.py", line 177, in colmap_build_map_from_loaded_data point_triangulator_options File "/home/jty/.local/lib/python3.6/site-packages/kapture_localization/colmap/colmap_command.py", line 275, in run_point_triangulator run_colmap_command(colmap_binary_path, point_triangulator_args) File "/home/jty/.local/lib/python3.6/site-packages/kapture_localization/colmap/colmap_command.py", line 70, in run_colmap_command '\nSubprocess Error (Return code:' ValueError: Subprocess Error (Return code: 1 ) Traceback (most recent call last): File "/home/jty/.local/bin/kapture_pipeline_mapping.py", line 249, in <module> mapping_pipeline_command_line() File "/home/jty/.local/bin/kapture_pipeline_mapping.py", line 239, in mapping_pipeline_command_line args.force) File "/home/jty/.local/bin/kapture_pipeline_mapping.py", line 150, in mapping_pipeline run_python_command(local_build_map_path, build_map_args, python_binary) File "/home/jty/.local/lib/python3.6/site-packages/kapture_localization/utils/subprocess.py", line 67, in run_python_command raise ValueError('\nSubprocess Error (Return code:' f' {python_process.returncode} )') ValueError: Subprocess Error (Return code: 1 )

hi, tyjiang1997 would you explain how did you solve this problem? I face similar Error on RobotCar_Seasons-v2 at the BA of mapping step: the log can be seen here: https://github.com/naver/kapture-localization/issues/18#issuecomment-906221179 colmap version is COLMAP 3.7 (Commit cf4a39c on 2021-06-22 with CUDA) Thanks