21 #include <boost/assign/std/vector.hpp> 25 using namespace gtsam;
39 Pose3 identity, aPb(aRb, aTb);
53 for (
size_t i = 0;
i < 2;
i++)
57 data.
tracks.push_back(track);
78 const string filename =
"../../examples/data/5pointExample1.txt";
94 Point3(0, 50, 50),
Point3(0, -50, 50),
Point3(-20, 0, 80),
Point3(20, -50, 80);
97 const string filename =
"../../examples/data/5pointExample2.txt";
104 int main(
int argc,
char* argv[]) {
void create5PointExample2()
bool writeBAL(const string &filename, SfmData &data)
This function writes a "Bundle Adjustment in the Large" (BAL) file from a SfmData structure...
Define the structure for SfM data.
void createExampleBALFile(const string &filename, const vector< Point3 > &P, const Pose3 &pose1, const Pose3 &pose2, const Cal3Bundler &K=Cal3Bundler())
static Cal3_S2 K(500, 500, 0.1, 640/2, 480/2)
void create5PointExample1()
std::vector< SfmTrack > tracks
Sparse set of points.
Define the structure for the 3D points.
static const Pose3 pose1(Rot3(), Point3(0, 1, 0.5))
Calibrated camera for which only pose is unknown.
int main(int argc, char *argv[])
std::vector< SfmCamera > cameras
Set of cameras.
Point3 p
3D position of the point
float b
RGB color of the 3D point.
PinholeCamera< Cal3Bundler > SfmCamera
Define the structure for the camera poses.
utility functions for loading datasets
std::vector< SfmMeasurement > measurements
The 2D image projections (id,(u,v))