22#ifndef EOS_READ_PTS_LANDMARKS_HPP
23#define EOS_READ_PTS_LANDMARKS_HPP
25#include "eos/core/Landmark.hpp"
46 using Eigen::Vector2f;
50 landmarks.reserve(68);
52 std::ifstream file(filename);
55 throw std::runtime_error(
string(
"Could not open landmark file: " + filename));
65 while (getline(file, line))
71 std::stringstream lineStream(line);
74 landmark.
name = std::to_string(ibugId);
77 throw std::runtime_error(
string(
"Landmark format error while parsing the line: " + line));
85 landmarks.emplace_back(landmark);
std::vector< Landmark< LandmarkType > > LandmarkCollection
A trivial collection of landmarks that belong together.
Definition: Landmark.hpp:47
LandmarkCollection< Eigen::Vector2f > read_pts_landmarks(std::string filename)
Definition: read_pts_landmarks.hpp:44
Namespace containing all of eos's 3D model fitting functionality.
Representation of a landmark, consisting of a landmark name and coordinates of the given type....
Definition: Landmark.hpp:38
std::string name
Name of the landmark, often used as identifier.
Definition: Landmark.hpp:39
LandmarkType coordinates
The position or coordinates of the landmark.
Definition: Landmark.hpp:40