ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
hierarchical_mapper.h
Go to the documentation of this file.
1
// ----------------------------------------------------------------------------
2
// - CloudViewer: www.cloudViewer.org -
3
// ----------------------------------------------------------------------------
4
// Copyright (c) 2018-2024 www.cloudViewer.org
5
// SPDX-License-Identifier: MIT
6
// ----------------------------------------------------------------------------
7
8
#pragma once
9
10
#include "
base/reconstruction_manager.h
"
11
#include "
base/scene_clustering.h
"
12
#include "
controllers/incremental_mapper.h
"
13
#include "
util/threading.h
"
14
15
namespace
colmap
{
16
17
// Hierarchical mapping first hierarchically partitions the scene into multiple
18
// overlapping clusters, then reconstructs them separately using incremental
19
// mapping, and finally merges them all into a globally consistent
20
// reconstruction. This is especially useful for larger-scale scenes, since
21
// incremental mapping becomes slow with an increasing number of images.
22
class
HierarchicalMapperController
:
public
Thread
{
23
public
:
24
struct
Options
{
25
// The path to the image folder which are used as input.
26
std::string
image_path
;
27
28
// The path to the database file which is used as input.
29
std::string
database_path
;
30
31
// The maximum number of trials to initialize a cluster.
32
int
init_num_trials
= 10;
33
34
// The number of workers used to reconstruct clusters in parallel.
35
int
num_workers
= -1;
36
37
bool
Check
()
const
;
38
};
39
40
HierarchicalMapperController
(
41
const
Options
& options,
42
const
SceneClustering::Options
& clustering_options,
43
const
IncrementalMapperOptions
& mapper_options,
44
ReconstructionManager
* reconstruction_manager);
45
46
private
:
47
void
Run()
override
;
48
49
const
Options
options_;
50
const
SceneClustering::Options
clustering_options_;
51
const
IncrementalMapperOptions
mapper_options_;
52
ReconstructionManager
* reconstruction_manager_;
53
};
54
55
}
// namespace colmap
colmap::HierarchicalMapperController
Definition:
hierarchical_mapper.h:22
colmap::HierarchicalMapperController::HierarchicalMapperController
HierarchicalMapperController(const Options &options, const SceneClustering::Options &clustering_options, const IncrementalMapperOptions &mapper_options, ReconstructionManager *reconstruction_manager)
Definition:
hierarchical_mapper.cc:78
colmap::ReconstructionManager
Definition:
reconstruction_manager.h:16
colmap::Thread
Definition:
threading.h:74
incremental_mapper.h
colmap
Definition:
AutomaticReconstructionController.h:17
reconstruction_manager.h
scene_clustering.h
colmap::HierarchicalMapperController::Options
Definition:
hierarchical_mapper.h:24
colmap::HierarchicalMapperController::Options::num_workers
int num_workers
Definition:
hierarchical_mapper.h:35
colmap::HierarchicalMapperController::Options::image_path
std::string image_path
Definition:
hierarchical_mapper.h:26
colmap::HierarchicalMapperController::Options::database_path
std::string database_path
Definition:
hierarchical_mapper.h:29
colmap::HierarchicalMapperController::Options::init_num_trials
int init_num_trials
Definition:
hierarchical_mapper.h:32
colmap::HierarchicalMapperController::Options::Check
bool Check() const
Definition:
hierarchical_mapper.cc:72
colmap::IncrementalMapperOptions
Definition:
incremental_mapper.h:16
colmap::SceneClustering::Options
Definition:
scene_clustering.h:23
threading.h
libs
Reconstruction
src
controllers
hierarchical_mapper.h
Generated on Tue Feb 3 2026 07:12:30 for ACloudViewer by
1.9.1