Doxygen documentation

release/4.3a0
Chris Beall 2011-09-07 22:05:13 +00:00
parent 72c2929ad6
commit 6a6634e28c
6 changed files with 44 additions and 43 deletions

View File

@ -152,6 +152,6 @@ namespace gtsam {
} }
}; };
typedef boost::shared_ptr<Cal3_S2> shared_ptrK; typedef boost::shared_ptr<Cal3_S2> shared_ptrK; ///< shared pointer to calibration object
} // gtsam } // gtsam

View File

@ -68,6 +68,6 @@ namespace gtsam {
} }
}; };
typedef boost::shared_ptr<Cal3_S2Stereo> shared_ptrKStereo; typedef boost::shared_ptr<Cal3_S2Stereo> shared_ptrKStereo; ///< shared pointer to stereo calibration object
} }

View File

@ -9,12 +9,13 @@
* -------------------------------------------------------------------------- */ * -------------------------------------------------------------------------- */
/* /**
* GeneralSFMFactor.h * @file GeneralSFMFactor.h
* *
* Created on: Dec 15, 2010 * @brief a general SFM factor with an unknown calibration
* Author: nikai *
* Description: a general SFM factor with an unknown calibration * @date Dec 15, 2010
* @author Kai Ni
*/ */
#pragma once #pragma once
@ -31,14 +32,14 @@ namespace gtsam {
class GeneralSFMFactor: class GeneralSFMFactor:
public NonlinearFactor2<VALUES, CamK, LmK> { public NonlinearFactor2<VALUES, CamK, LmK> {
protected: protected:
Point2 z_; Point2 z_; ///< the 2D measurement
public: public:
typedef typename CamK::Value Cam; typedef typename CamK::Value Cam; ///< typedef for camera type
typedef GeneralSFMFactor<VALUES, CamK, LmK> Self ; typedef GeneralSFMFactor<VALUES, CamK, LmK> Self ; ///< typedef for this object
typedef NonlinearFactor2<VALUES, CamK, LmK> Base; typedef NonlinearFactor2<VALUES, CamK, LmK> Base; ///< typedef for the base class
typedef Point2 Measurement; typedef Point2 Measurement; ///< typedef for the measurement
// shorthand for a smart pointer to a factor // shorthand for a smart pointer to a factor
typedef boost::shared_ptr<GeneralSFMFactor<VALUES, LmK, CamK> > shared_ptr; typedef boost::shared_ptr<GeneralSFMFactor<VALUES, LmK, CamK> > shared_ptr;
@ -46,18 +47,17 @@ namespace gtsam {
/** /**
* Constructor * Constructor
* @param z is the 2 dimensional location of point in image (the measurement) * @param z is the 2 dimensional location of point in image (the measurement)
* @param sigma is the standard deviation * @param model is the standard deviation of the measurements
* @param cameraFrameNumber is basically the frame number * @param i is basically the frame number
* @param landmarkNumber is the index of the landmark * @param j is the index of the landmark
* @param K the constant calibration
*/ */
GeneralSFMFactor():z_(0.0,0.0) {}
GeneralSFMFactor(const Point2 & p):z_(p) {}
GeneralSFMFactor(double x, double y):z_(x,y) {}
GeneralSFMFactor(const Point2& z, const SharedNoiseModel& model, const CamK& i, const LmK& j) : Base(model, i, j), z_(z) {} GeneralSFMFactor(const Point2& z, const SharedNoiseModel& model, const CamK& i, const LmK& j) : Base(model, i, j), z_(z) {}
virtual ~GeneralSFMFactor() {} GeneralSFMFactor():z_(0.0,0.0) {} ///< default constructor
GeneralSFMFactor(const Point2 & p):z_(p) {} ///< constructor that takes a Point2
GeneralSFMFactor(double x, double y):z_(x,y) {} ///< constructor that takes doubles x,y to make a Point2
virtual ~GeneralSFMFactor() {} ///< destructor
/** /**
* print * print

View File

@ -34,8 +34,8 @@ namespace gtsam {
protected: protected:
// Keep a copy of measurement and calibration for I/O // Keep a copy of measurement and calibration for I/O
Point2 z_; Point2 z_; ///< 2D measurement
boost::shared_ptr<Cal3_S2> K_; boost::shared_ptr<Cal3_S2> K_; ///< shared pointer to calibration object
public: public:
@ -53,10 +53,10 @@ namespace gtsam {
/** /**
* Constructor * Constructor
* @param z is the 2 dimensional location of point in image (the measurement) * @param z is the 2 dimensional location of point in image (the measurement)
* @param sigma is the standard deviation * @param model is the standard deviation
* @param cameraFrameNumber is basically the frame number * @param j_pose is basically the frame number
* @param landmarkNumber is the index of the landmark * @param j_landmark is the index of the landmark
* @param K the constant calibration * @param K shared pointer to the constant calibration
*/ */
GenericProjectionFactor(const Point2& z, const SharedNoiseModel& model, GenericProjectionFactor(const Point2& z, const SharedNoiseModel& model,
POSK j_pose, LMK j_landmark, const shared_ptrK& K) : POSK j_pose, LMK j_landmark, const shared_ptrK& K) :

View File

@ -27,16 +27,15 @@ class GenericStereoFactor: public NonlinearFactor2<VALUES, KEY1, KEY2> {
private: private:
// Keep a copy of measurement and calibration for I/O // Keep a copy of measurement and calibration for I/O
StereoPoint2 z_; StereoPoint2 z_; ///< the measurement
boost::shared_ptr<Cal3_S2Stereo> K_; boost::shared_ptr<Cal3_S2Stereo> K_; ///< shared pointer to calibration
public: public:
// shorthand for base class type // shorthand for base class type
typedef NonlinearFactor2<VALUES, KEY1, KEY2> Base; typedef NonlinearFactor2<VALUES, KEY1, KEY2> Base; ///< typedef for base class
typedef boost::shared_ptr<GenericStereoFactor> shared_ptr; typedef boost::shared_ptr<GenericStereoFactor> shared_ptr; ///< typedef for shared pointer to this object
typedef typename KEY1::Value CamPose; typedef typename KEY1::Value CamPose; ///< typedef for Pose Lie Value type
typedef StereoPoint2 Measurement;
/** /**
* Default constructor * Default constructor
@ -45,10 +44,10 @@ public:
/** /**
* Constructor * Constructor
* @param z is the 2 dimensional location of point in image (the measurement) * @param z is the Stereo Point measurement (u_l, u_r, v). v will be identical for left & right for rectified stereo pair
* @param sigma is the standard deviation * @param model is the noise model in on the measurement
* @param cameraFrameNumber is basically the frame number * @param j_pose the pose index
* @param landmarkNumber is the index of the landmark * @param j_landmark the landmark index
* @param K the constant calibration * @param K the constant calibration
*/ */
GenericStereoFactor(const StereoPoint2& z, const SharedNoiseModel& model, KEY1 j_pose, GenericStereoFactor(const StereoPoint2& z, const SharedNoiseModel& model, KEY1 j_pose,
@ -56,7 +55,7 @@ public:
Base(model, j_pose, j_landmark), z_(z), K_(K) { Base(model, j_pose, j_landmark), z_(z), K_(K) {
} }
~GenericStereoFactor() {} ~GenericStereoFactor() {} ///< desctructor
/** /**
* print * print
@ -91,6 +90,7 @@ public:
return (stereoCam.project(point, H1, H2) - z_).vector(); return (stereoCam.project(point, H1, H2) - z_).vector();
} }
/// get the measurement z
StereoPoint2 z() { StereoPoint2 z() {
return z_; return z_;
} }

View File

@ -9,11 +9,12 @@
* -------------------------------------------------------------------------- */ * -------------------------------------------------------------------------- */
/* /**
* visualSLAM.h * @file visualSLAM.h
* * @brief Basic typedefs for general VisualSLAM problems. Useful for monocular and stereo systems.
* Created on: Jan 14, 2010 * @date Jan 14, 2010
* Author: Richard Roberts and Chris Beall * @author Richard Roberts
* @author Chris Beall
*/ */
#pragma once #pragma once