Static functions for bundle adjustment.
More...
#include <vpgl_bundle_adjust.h>
Static functions for bundle adjustment.
Definition at line 27 of file vpgl_bundle_adjust.h.
◆ vpgl_bundle_adjust()
| vpgl_bundle_adjust::vpgl_bundle_adjust |
( |
| ) |
|
◆ ~vpgl_bundle_adjust()
| vpgl_bundle_adjust::~vpgl_bundle_adjust |
( |
| ) |
|
◆ cam_params()
| const vnl_vector<double>& vpgl_bundle_adjust::cam_params |
( |
| ) |
const |
|
inline |
◆ depth_reverse()
Approximately depth invert the scene.
Apply this and re-optimize to get out of a common local minimum. Find the mean axis between cameras and points, mirror the points about a plane perpendicular to this axis, and rotate the cameras 180 degrees around this axis
Definition at line 116 of file vpgl_bundle_adjust.cxx.
◆ end_error()
| double vpgl_bundle_adjust::end_error |
( |
| ) |
const |
|
inline |
◆ final_weights()
| const std::vector<double>& vpgl_bundle_adjust::final_weights |
( |
| ) |
const |
|
inline |
◆ normalize_points()
| void vpgl_bundle_adjust::normalize_points |
( |
std::vector< vgl_point_2d< double > > & |
image_points, |
|
|
double & |
nx, |
|
|
double & |
ny, |
|
|
double & |
ns |
|
) |
| |
|
private |
normalize image points to be mean centered with scale sqrt(2).
- Returns
- parameters such that original point are recovered as (ns*x+nx, ns*y+ny)
Definition at line 47 of file vpgl_bundle_adjust.cxx.
◆ num_iterations()
| int vpgl_bundle_adjust::num_iterations |
( |
| ) |
const |
|
inline |
◆ optimize()
| bool vpgl_bundle_adjust::optimize |
( |
std::vector< vpgl_perspective_camera< double > > & |
cameras, |
|
|
std::vector< vgl_point_3d< double > > & |
world_points, |
|
|
const std::vector< vgl_point_2d< double > > & |
image_points, |
|
|
const std::vector< std::vector< bool > > & |
mask |
|
) |
| |
Bundle Adjust.
- Parameters
-
| mask | should have the same number of entries as |
| cameras,and | each entry of |
| mask | should be the same size as |
| world_points. | mask[i][j] is true if point j is visible from camera i |
| image_points | and is a linear list of the 2D locations of the 3D points as seen by the cameras. There is one image point for every true in |
| mask. | The following piece of code shows the structure of |
| image_points | for( int c = 0; c < num_cameras; c++ ){ for( int dp = 0; dp < num_world_points; dp++ ){ if( mask[c][dp] ) img_points.push_back( all_image_points[c*num_world_points+dp] ); } } |
Definition at line 149 of file vpgl_bundle_adjust.cxx.
◆ point_params()
| const vnl_vector<double>& vpgl_bundle_adjust::point_params |
( |
| ) |
const |
|
inline |
◆ reflect_points()
| void vpgl_bundle_adjust::reflect_points |
( |
const vgl_plane_3d< double > & |
plane, |
|
|
std::vector< vgl_point_3d< double > > & |
points |
|
) |
| |
|
private |
◆ rotate_cameras()
◆ set_epsilon()
| void vpgl_bundle_adjust::set_epsilon |
( |
double |
eps | ) |
|
|
inline |
◆ set_g_tolerence()
| void vpgl_bundle_adjust::set_g_tolerence |
( |
double |
gtol | ) |
|
|
inline |
◆ set_m_estimator_scale()
| void vpgl_bundle_adjust::set_m_estimator_scale |
( |
double |
scale | ) |
|
|
inline |
◆ set_max_iterations()
| void vpgl_bundle_adjust::set_max_iterations |
( |
unsigned |
maxitr | ) |
|
|
inline |
◆ set_normalize_data()
| void vpgl_bundle_adjust::set_normalize_data |
( |
bool |
normalize | ) |
|
|
inline |
◆ set_self_calibrate()
| void vpgl_bundle_adjust::set_self_calibrate |
( |
bool |
self_calibrate | ) |
|
|
inline |
◆ set_use_gradient()
| void vpgl_bundle_adjust::set_use_gradient |
( |
bool |
use_gradient | ) |
|
|
inline |
◆ set_use_m_estimator()
| void vpgl_bundle_adjust::set_use_m_estimator |
( |
bool |
use_m | ) |
|
|
inline |
◆ set_verbose()
| void vpgl_bundle_adjust::set_verbose |
( |
bool |
verbose | ) |
|
|
inline |
◆ set_x_tolerence()
| void vpgl_bundle_adjust::set_x_tolerence |
( |
double |
xtol | ) |
|
|
inline |
◆ start_error()
| double vpgl_bundle_adjust::start_error |
( |
| ) |
const |
|
inline |
◆ write_vrml()
| void vpgl_bundle_adjust::write_vrml |
( |
const std::string & |
filename, |
|
|
const std::vector< vpgl_perspective_camera< double > > & |
cameras, |
|
|
const std::vector< vgl_point_3d< double > > & |
world_points |
|
) |
| |
|
static |
◆ a_
◆ b_
◆ ba_func_
◆ c_
◆ end_error_
| double vpgl_bundle_adjust::end_error_ |
|
private |
◆ epsilon_
| double vpgl_bundle_adjust::epsilon_ |
|
private |
◆ g_tol_
| double vpgl_bundle_adjust::g_tol_ |
|
private |
◆ m_estimator_scale_
| double vpgl_bundle_adjust::m_estimator_scale_ |
|
private |
◆ max_iterations_
| unsigned int vpgl_bundle_adjust::max_iterations_ |
|
private |
◆ normalize_data_
| bool vpgl_bundle_adjust::normalize_data_ |
|
private |
◆ num_iterations_
| int vpgl_bundle_adjust::num_iterations_ |
|
private |
◆ self_calibrate_
| bool vpgl_bundle_adjust::self_calibrate_ |
|
private |
◆ start_error_
| double vpgl_bundle_adjust::start_error_ |
|
private |
◆ use_gradient_
| bool vpgl_bundle_adjust::use_gradient_ |
|
private |
◆ use_m_estimator_
| bool vpgl_bundle_adjust::use_m_estimator_ |
|
private |
◆ verbose_
| bool vpgl_bundle_adjust::verbose_ |
|
private |
◆ weights_
| std::vector<double> vpgl_bundle_adjust::weights_ |
|
private |
◆ x_tol_
| double vpgl_bundle_adjust::x_tol_ |
|
private |
The documentation for this class was generated from the following files: