Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

training error about colmap #2

Open
serizawa-04013958 opened this issue Oct 16, 2024 · 1 comment
Open

training error about colmap #2

serizawa-04013958 opened this issue Oct 16, 2024 · 1 comment

Comments

@serizawa-04013958
Copy link

Hello, thank you for your great work.
I'd like to train your code by candlefiat, I faced below errors.
do you know how to use training dataset?

`Output folder: /cig/common06nb/deserizk/HDRSplat/output/candlefiat
Optimizing /cig/common06nb/deserizk/HDRSplat/output/candlefiat
/cig/common06nb/deserizk/archive/rawnerf/scenes/candlefiat/sparse [16/10 15:35:51]
demosaic [16/10 15:35:51]

Reading camera 1/52Traceback (most recent call last):
File "/cig/common06nb/deserizk/HDRSplat/train.py", line 352, in
training(lp.extract(args), op.extract(args), pp.extract(args), args.render_iterations, args.test_iterations, args.save_iterations, args.checkpoint_iterations, args.start_checkpoint, args.debug_from)
File "/cig/common06nb/deserizk/HDRSplat/train.py", line 62, in training
scene = Scene(dataset, gaussians)
File "/cig/common06nb/deserizk/HDRSplat/scene/init.py", line 52, in init
scene_info = self.callback["Colmap"](args.source_path, args.images, args.eval, "demosaic", args.denoise_method)
File "/cig/common06nb/deserizk/HDRSplat/scene/dataset_readers_raw.py", line 202, in readColmapSceneInfo
cam_infos_unsorted = readColmapCameras(cam_extrinsics=cam_extrinsics, cam_intrinsics=cam_intrinsics, images_folder=os.path.join(path, reading_img_dir), raw_folder=os.path.join(path, reading_raw_dir),scene_path=path, denoise_method=denoise_method)
File "/cig/common06nb/deserizk/HDRSplat/scene/dataset_readers_raw.py", line 125, in readColmapCameras
assert False, "Colmap camera model not handled: only undistorted datasets (PINHOLE or SIMPLE_PINHOLE cameras) supported!"
AssertionError: Colmap camera model not handled: only undistorted datasets (PINHOLE or SIMPLE_PINHOLE cameras) supported!`

@shreyesss
Copy link
Owner

shreyesss commented Oct 16, 2024

3DGS implementation only supports simple pinhole camera model for now, to convert the dataset to simple pinhole camera model, install colmap CLI and follow these steps:

$ DATASET_PATH=/path/to/dataset

$ colmap feature_extractor
--database_path $DATASET_PATH/database.db
--image_path $DATASET_PATH/images

$ colmap exhaustive_matcher
--database_path $DATASET_PATH/database.db

$ mkdir $DATASET_PATH/sparse

$ colmap mapper
--database_path $DATASET_PATH/database.db
--image_path $DATASET_PATH/images
--output_path $DATASET_PATH/sparse

$ mkdir $DATASET_PATH/dense

$ colmap image_undistorter
--image_path $DATASET_PATH/images
--input_path $DATASET_PATH/sparse/0
--output_path $DATASET_PATH/dense
--output_type COLMAP
--max_image_size 2000

For more details refer to: 
https://colmap.github.io/cli.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants