Functions
sba.cpp File Reference

Definitions for sparse bundle adjustment related functions. More...

#include "sba.hpp"
Include dependency graph for sba.cpp:

Go to the source code of this file.

Functions

void addPointsToSBA (SysSBA &sba, vector< cv::Point3d > &cloud)
void addProjectionsToSBA (SysSBA &sba, vector< cv::Point2f > &loc, int idx)
void addProjectionToSBA (SysSBA &sba, cv::Point2f &loc, unsigned int trackNo, unsigned int camNo)
double adjustFullSystem (vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, unsigned int min_index, unsigned int max_index, unsigned int its)
void assignFullSystem (SysSBA &sba, vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, unsigned int start_index, unsigned int finish_index, bool dummy)
void assignPartialSystem (SysSBA &sba, vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, vector< unsigned int > &indices, bool assignProjections)
void assignSystem (SysSBA &sba, vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, vector< unsigned int > &camera_indices, vector< unsigned int > &track_indices)
void copySys (const SysSBA &src, SysSBA &dst)
double determineSystemSize (SysSBA &sys)
 Determines distance between farthest cameras.
double distanceBetweenPoints (Eigen::Matrix< double, 4, 1 > &pt1, Eigen::Matrix< double, 4, 1 > &pt2)
void drawGraph2 (const SysSBA &sba, const ros::Publisher &camera_pub, const ros::Publisher &point_pub, const ros::Publisher &path_pub, int decimation, int bicolor, double scale)
void drawKeyframes (const ros::Publisher &camera_pub, const geometry_msgs::PoseStamped *keyframePoses, unsigned int keyframeCount)
int estimatePoseBetweenCameras (cameraParameters &camData, vector< cv::Point2f > &pts1, vector< cv::Point2f > &pts2, cv::Mat &C)
void extractCameras (const SysSBA &sba, visualization_msgs::MarkerArray &cameraArray, visualization_msgs::Marker &marker_path)
void extractPointCloud (const SysSBA &sba, pcl::PointCloud< pcl::PointXYZ > &point_cloud)
void findCentroid (SysSBA &sba, cv::Point3d &centroid, cv::Point3d &stdDeviation)
void findIntermediatePoses (vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, unsigned int image_idx_1, unsigned int image_idx_2, bool fixBothEnds)
void findRelevantIndices (vector< featureTrack > &tracks, vector< unsigned int > &triangulated, vector< unsigned int > &untriangulated, unsigned int last_index, unsigned int new_index)
void finishTracks (vector< featureTrack > &tracks, vector< cv::Point2f > &pts, double retainProp, unsigned int maxOccurrences)
void getActiveCameras (cv::Mat *C, vector< unsigned int > &indices, unsigned int min_index, unsigned int max_index)
void getActiveTracks (vector< featureTrack > &tracks, vector< unsigned int > &cameras, vector< unsigned int > &indices)
double getFeatureMotion (vector< featureTrack > &tracks, vector< unsigned int > &indices, unsigned int idx_1, unsigned int idx_2)
void initializeFrameCamera (frame_common::CamParams &cam_params, const cv::Mat &newCamMat, int &maxx, int &maxy, const cv::Size &cameraSize)
double keyframeBundleAdjustment (cameraParameters &camData, vector< featureTrack > &tracks, cv::Mat *cameras, vector< unsigned int > &indices, unsigned int iterations, bool allFree, bool allFixedExceptLast, unsigned int fixed_cams)
double keyframeBundleAdjustment (cameraParameters &camData, vector< featureTrack > &tracks, keyframeStore &kf_store, cv::Mat *cameras, unsigned int kfIndex, unsigned int iterations)
void normalizeSystem (SysSBA &sys, double factor)
 Scales up system size.
double odometryBundleAdjustment (cameraParameters &camData, vector< featureTrack > &tracks, geometry_msgs::PoseStamped *keyframePoses, unsigned int keyframeCount, unsigned int iterations, bool debug)
void optimizeFullSystem (vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, unsigned int last_index)
double optimizeKeyframePair (vector< featureTrack > &tracks, cameraParameters &camData, int idx1, int idx2, cv::Mat *cameras)
double optimizeSubsystem (cameraParameters &camData, cv::Mat *C, vector< unsigned int > &c_i, vector< featureTrack > &tracks, vector< unsigned int > &t_i, unsigned int iterations)
double optimizeSystem (SysSBA &sba, double err, int iterations, bool debug, int mode)
 *
bool overwritePoints (const SysSBA &sys, const vector< int > &track_indices, vector< featureTrack > &tracks, double maxDisplacement, double *averagePointShift, bool debug)
double predictiveBundleAdjustment (cameraParameters &camData, vector< featureTrack > &tracks, geometry_msgs::PoseStamped *keyframePoses, bool *keyframeTypes, unsigned int keyframeCount, geometry_msgs::PoseStamped &newPose, unsigned int iterations, bool debug, int mode, double err, int *triangulations, double *averagePointShift)
bool reconstructFreshSubsequencePair (vector< featureTrack > &tracks, vector< cv::Point3d > &ptCloud, vector< unsigned int > &triangulatedIndices, cv::Mat &real_C0, cv::Mat &real_C1, cameraParameters camData, int idx1, int idx2)
void removePoorTracks (vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, unsigned int start_cam, unsigned int finish_cam)
void renormalizeSBA (SysSBA &sba, cv::Point3d &desiredCenter)
void rescaleSBA (SysSBA &sba, unsigned int idx1, unsigned int idx2)
void retrieveFullSystem (SysSBA &sys, cv::Mat *C, vector< featureTrack > &tracks, unsigned int start_cam, unsigned int final_cam)
void retrievePartialSystem (SysSBA &sys, cv::Mat *C, vector< featureTrack > &tracks, vector< unsigned int > &indices)
void retrieveSystem (SysSBA &sba, vector< featureTrack > &tracks, cameraParameters &camData, cv::Mat *cameras, vector< unsigned int > &camera_indices, vector< unsigned int > &track_indices)
void subselectPoints (const vector< cv::Point2f > &src1, vector< cv::Point2f > &dst1, const vector< cv::Point2f > &src2, vector< cv::Point2f > &dst2)
double testKeyframePair (vector< featureTrack > &tracks, cameraParameters &camData, double *scorecard[], int idx1, int idx2, double *score, cv::Mat &pose, bool evaluate, bool debug)
double twoViewBundleAdjustment (cameraParameters cam_data, cv::Mat &cam1, cv::Mat &cam2, vector< cv::Point3d > &cloud, vector< cv::Point2f > &pts1, vector< cv::Point2f > &pts2, int iterations)

Detailed Description

Definitions for sparse bundle adjustment related functions.

Definition in file sba.cpp.


Function Documentation

void addPointsToSBA ( SysSBA &  sba,
vector< cv::Point3d > &  cloud 
)

Definition at line 2457 of file sba.cpp.

void addProjectionsToSBA ( SysSBA &  sba,
vector< cv::Point2f > &  loc,
int  idx 
)

Definition at line 2489 of file sba.cpp.

void addProjectionToSBA ( SysSBA &  sba,
cv::Point2f &  loc,
unsigned int  trackNo,
unsigned int  camNo 
)

Definition at line 2481 of file sba.cpp.

double adjustFullSystem ( vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
unsigned int  min_index,
unsigned int  max_index,
unsigned int  its 
)

Definition at line 1560 of file sba.cpp.

void assignFullSystem ( SysSBA &  sba,
vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
unsigned int  start_index,
unsigned int  finish_index,
bool  dummy 
)

Definition at line 1652 of file sba.cpp.

void assignPartialSystem ( SysSBA &  sba,
vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
vector< unsigned int > &  indices,
bool  assignProjections 
)

Definition at line 1498 of file sba.cpp.

void assignSystem ( SysSBA &  sba,
vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
vector< unsigned int > &  camera_indices,
vector< unsigned int > &  track_indices 
)

Definition at line 1606 of file sba.cpp.

void copySys ( const SysSBA &  src,
SysSBA &  dst 
)

Definition at line 296 of file sba.cpp.

double determineSystemSize ( SysSBA &  sys)

Determines distance between farthest cameras.

Definition at line 859 of file sba.cpp.

double distanceBetweenPoints ( Eigen::Matrix< double, 4, 1 > &  pt1,
Eigen::Matrix< double, 4, 1 > &  pt2 
)

Definition at line 845 of file sba.cpp.

void drawGraph2 ( const SysSBA &  sba,
const ros::Publisher camera_pub,
const ros::Publisher point_pub,
const ros::Publisher path_pub,
int  decimation,
int  bicolor,
double  scale 
)

Definition at line 2741 of file sba.cpp.

void drawKeyframes ( const ros::Publisher camera_pub,
const geometry_msgs::PoseStamped *  keyframePoses,
unsigned int  keyframeCount 
)

Definition at line 2618 of file sba.cpp.

int estimatePoseBetweenCameras ( cameraParameters camData,
vector< cv::Point2f > &  pts1,
vector< cv::Point2f > &  pts2,
cv::Mat &  C 
)

Definition at line 1928 of file sba.cpp.

void extractCameras ( const SysSBA &  sba,
visualization_msgs::MarkerArray &  cameraArray,
visualization_msgs::Marker &  marker_path 
)

Definition at line 2527 of file sba.cpp.

void extractPointCloud ( const SysSBA &  sba,
pcl::PointCloud< pcl::PointXYZ > &  point_cloud 
)

Definition at line 2515 of file sba.cpp.

void findCentroid ( SysSBA &  sba,
cv::Point3d &  centroid,
cv::Point3d &  stdDeviation 
)

Definition at line 398 of file sba.cpp.

void findIntermediatePoses ( vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
unsigned int  image_idx_1,
unsigned int  image_idx_2,
bool  fixBothEnds 
)

Definition at line 43 of file sba.cpp.

void findRelevantIndices ( vector< featureTrack > &  tracks,
vector< unsigned int > &  triangulated,
vector< unsigned int > &  untriangulated,
unsigned int  last_index,
unsigned int  new_index 
)

Definition at line 7 of file sba.cpp.

void finishTracks ( vector< featureTrack > &  tracks,
vector< cv::Point2f > &  pts,
double  retainProp,
unsigned int  maxOccurrences 
)

Definition at line 3051 of file sba.cpp.

void getActiveCameras ( cv::Mat *  C,
vector< unsigned int > &  indices,
unsigned int  min_index,
unsigned int  max_index 
)

Definition at line 1293 of file sba.cpp.

void getActiveTracks ( vector< featureTrack > &  tracks,
vector< unsigned int > &  cameras,
vector< unsigned int > &  indices 
)

Definition at line 1301 of file sba.cpp.

double getFeatureMotion ( vector< featureTrack > &  tracks,
vector< unsigned int > &  indices,
unsigned int  idx_1,
unsigned int  idx_2 
)

Definition at line 164 of file sba.cpp.

void initializeFrameCamera ( frame_common::CamParams &  cam_params,
const cv::Mat &  newCamMat,
int &  maxx,
int &  maxy,
const cv::Size &  cameraSize 
)

Definition at line 2605 of file sba.cpp.

double keyframeBundleAdjustment ( cameraParameters camData,
vector< featureTrack > &  tracks,
cv::Mat *  cameras,
vector< unsigned int > &  indices,
unsigned int  iterations,
bool  allFree,
bool  allFixedExceptLast,
unsigned int  fixed_cams 
)

Definition at line 460 of file sba.cpp.

double keyframeBundleAdjustment ( cameraParameters camData,
vector< featureTrack > &  tracks,
keyframeStore kf_store,
cv::Mat *  cameras,
unsigned int  kfIndex,
unsigned int  iterations 
)

Definition at line 615 of file sba.cpp.

void normalizeSystem ( SysSBA &  sys,
double  factor 
)

Scales up system size.

Definition at line 873 of file sba.cpp.

double odometryBundleAdjustment ( cameraParameters camData,
vector< featureTrack > &  tracks,
geometry_msgs::PoseStamped *  keyframePoses,
unsigned int  keyframeCount,
unsigned int  iterations,
bool  debug 
)

Definition at line 1107 of file sba.cpp.

void optimizeFullSystem ( vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
unsigned int  last_index 
)

Definition at line 423 of file sba.cpp.

double optimizeKeyframePair ( vector< featureTrack > &  tracks,
cameraParameters camData,
int  idx1,
int  idx2,
cv::Mat *  cameras 
)

Definition at line 1466 of file sba.cpp.

double optimizeSubsystem ( cameraParameters camData,
cv::Mat *  C,
vector< unsigned int > &  c_i,
vector< featureTrack > &  tracks,
vector< unsigned int > &  t_i,
unsigned int  iterations 
)

Definition at line 1372 of file sba.cpp.

double optimizeSystem ( SysSBA &  sba,
double  err,
int  iterations,
bool  debug,
int  mode 
)

*

* *

Definition at line 2354 of file sba.cpp.

bool overwritePoints ( const SysSBA &  sys,
const vector< int > &  track_indices,
vector< featureTrack > &  tracks,
double  maxDisplacement,
double *  averagePointShift,
bool  debug 
)

Definition at line 1215 of file sba.cpp.

double predictiveBundleAdjustment ( cameraParameters camData,
vector< featureTrack > &  tracks,
geometry_msgs::PoseStamped *  keyframePoses,
bool *  keyframeTypes,
unsigned int  keyframeCount,
geometry_msgs::PoseStamped &  newPose,
unsigned int  iterations,
bool  debug,
int  mode,
double  err,
int *  triangulations,
double *  averagePointShift 
)

Definition at line 888 of file sba.cpp.

bool reconstructFreshSubsequencePair ( vector< featureTrack > &  tracks,
vector< cv::Point3d > &  ptCloud,
vector< unsigned int > &  triangulatedIndices,
cv::Mat &  real_C0,
cv::Mat &  real_C1,
cameraParameters  camData,
int  idx1,
int  idx2 
)

Definition at line 1722 of file sba.cpp.

void removePoorTracks ( vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
unsigned int  start_cam,
unsigned int  finish_cam 
)

Definition at line 232 of file sba.cpp.

void renormalizeSBA ( SysSBA &  sba,
cv::Point3d &  desiredCenter 
)

Definition at line 335 of file sba.cpp.

void rescaleSBA ( SysSBA &  sba,
unsigned int  idx1,
unsigned int  idx2 
)

Definition at line 311 of file sba.cpp.

void retrieveFullSystem ( SysSBA &  sys,
cv::Mat *  C,
vector< featureTrack > &  tracks,
unsigned int  start_cam,
unsigned int  final_cam 
)

Definition at line 1338 of file sba.cpp.

void retrievePartialSystem ( SysSBA &  sys,
cv::Mat *  C,
vector< featureTrack > &  tracks,
vector< unsigned int > &  indices 
)

Definition at line 1258 of file sba.cpp.

void retrieveSystem ( SysSBA &  sba,
vector< featureTrack > &  tracks,
cameraParameters camData,
cv::Mat *  cameras,
vector< unsigned int > &  camera_indices,
vector< unsigned int > &  track_indices 
)

Definition at line 1593 of file sba.cpp.

void subselectPoints ( const vector< cv::Point2f > &  src1,
vector< cv::Point2f > &  dst1,
const vector< cv::Point2f > &  src2,
vector< cv::Point2f > &  dst2 
)

Definition at line 1824 of file sba.cpp.

double testKeyframePair ( vector< featureTrack > &  tracks,
cameraParameters camData,
double *  scorecard[],
int  idx1,
int  idx2,
double *  score,
cv::Mat &  pose,
bool  evaluate,
bool  debug 
)

Definition at line 1944 of file sba.cpp.

double twoViewBundleAdjustment ( cameraParameters  cam_data,
cv::Mat &  cam1,
cv::Mat &  cam2,
vector< cv::Point3d > &  cloud,
vector< cv::Point2f > &  pts1,
vector< cv::Point2f > &  pts2,
int  iterations 
)

Definition at line 2431 of file sba.cpp.



thermalvis
Author(s): Stephen Vidas
autogenerated on Sun Jan 5 2014 11:38:45