Formula Student Autonomous Systems
The code for the main driverless system
Loading...
Searching...
No Matches
lap_counter.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include "
loop_closure.hpp
"
4
9
class
LapCounter
:
public
LoopClosure
{
10
public
:
17
LapCounter
(
double
threshold_dist,
int
first_x_cones,
int
border_width,
int
minimum_confidence);
18
29
Result
detect
(
const
Eigen::Vector3d& current_pose,
const
Eigen::VectorXd& map_cones,
30
const
Eigen::VectorXi& associations,
31
const
Eigen::VectorXd& observations)
const override
;
32
33
private
:
34
double
threshold_dist_
;
// TODO: make this const or create parameters struct
35
int
first_x_cones_
;
36
int
border_width_
;
37
int
minimum_confidence_
;
38
mutable
bool
searching_
{
false
};
39
};
LapCounter
Implementation of LoopClosure that detects when the robot returns near the origin and re‑observes any...
Definition
lap_counter.hpp:9
LapCounter::searching_
bool searching_
Definition
lap_counter.hpp:38
LapCounter::first_x_cones_
int first_x_cones_
Definition
lap_counter.hpp:35
LapCounter::border_width_
int border_width_
Definition
lap_counter.hpp:36
LapCounter::threshold_dist_
double threshold_dist_
Definition
lap_counter.hpp:34
LapCounter::detect
Result detect(const Eigen::Vector3d ¤t_pose, const Eigen::VectorXd &map_cones, const Eigen::VectorXi &associations, const Eigen::VectorXd &observations) const override
Detects loop closure when returning to origin and seeing initial cones.
Definition
lap_counter.cpp:13
LapCounter::minimum_confidence_
int minimum_confidence_
Definition
lap_counter.hpp:37
LoopClosure
Interface for detecting loop closures.
Definition
loop_closure.hpp:11
loop_closure.hpp
LoopClosure::Result
Result of loop closure detection.
Definition
loop_closure.hpp:18
src
perception_sensor_lib
include
perception_sensor_lib
loop_closure
lap_counter.hpp
Generated by
1.9.8