struct mola::state_estimation_smoother::StateEstimationSmoother::State
Overview
struct State { // fields mrpt::pimpl<GtsamImpl> gtsam; frame_index_t next_frame_index = 0; mrpt::containers::bimap<mrpt::Clock::time_point, frame_index_t> stamp2frame_index; mrpt::containers::bimap<std::string, odometry_frameid_t> known_odom_frames; std::map<frame_index_t, FrameState> last_estimated_states; std::map<odometry_frameid_t, mrpt::poses::CPose3DPDFGaussian> last_estimated_frames; std::optional<mrpt::Clock::time_point> last_observation_stamp; mrpt::Clock::time_point last_observation_wallclock_stamp; std::optional<mrpt::poses::CPose2D> last_wheels_odometry; std::optional<std::string> last_wheels_odometry_name; std::optional<mola::Georeferencing> geo_reference; std::optional<mrpt::topography::TGeodeticCoords> tentative_geo_coord_reference; bool estimated_georef_published = false; RegexCache do_process_imu_labels_re; RegexCache do_process_odometry_labels_re; RegexCache do_process_gnss_labels_re; // methods std::optional<mrpt::Clock::time_point> get_current_extrapolated_stamp() const; };
Fields
frame_index_t next_frame_index = 0
The next numeric ID to assign to a new frame, for usage in GTSAM symbols P(i), v(i)…
mrpt::containers::bimap<mrpt::Clock::time_point, frame_index_t> stamp2frame_index
A bimap of timestamps <=> frame indices. Updated by.
mrpt::containers::bimap<std::string, odometry_frameid_t> known_odom_frames
A bimap of known odometry “frame_id” <=> “numeric IDs”:
std::map<frame_index_t, FrameState> last_estimated_states
The latest values from the estimator; updated in process_pending_gtsam_updates()
std::map<odometry_frameid_t, mrpt::poses::CPose3DPDFGaussian> last_estimated_frames
The latest values from the estimator; updated in process_pending_gtsam_updates()
std::optional<mola::Georeferencing> geo_reference
Refer to Parameters for possible sources of this. Anyways: this will always hold either the estimated or the fixed (externally set) georeferencing parameters. When this is still empty, it means we are still waiting for someone external to send us the georeferencing data, or our internal estimator didn’t obtained a quality estimation yet.
std::optional<mrpt::topography::TGeodeticCoords> tentative_geo_coord_reference
Will be populated with the first GNSS coords when in active estimation mode.
bool estimated_georef_published = false
Flag to track if we’ve already published the estimated geo-ref.
Methods
std::optional<mrpt::Clock::time_point> get_current_extrapolated_stamp() const
For real-time mode operation (not offline): returns the current extrapolated stamp, by adding the difference between the last observation wallclock time and now to the last observation timestamp.