Bratmobile
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
Tracker Class Referenceabstract

Tracking interface: Bridge between the real world and the simulation. Is used for tracking execution of tasks and using lived experience to modify the state-matching threshold. More...

#include <tracker.h>

Inheritance diagram for Tracker:
Inheritance graph
[legend]
Collaboration diagram for Tracker:
Collaboration graph
[legend]

Public Member Functions

Thresholdget_threshold ()
 
void register_learner (ThresholdLearner *l)
 
b2Transform getDeltaTransform ()
 
virtual TrackingResult get_transform (const Task &t, const CoordinateContainer &pts, const std::vector< BodyFeatures > &objects)
 
virtual TrackingResult track (const Task &t, const CoordinateContainer &pts, const std::vector< BodyFeatures > &objects)=0
 Tracks task execution. More...
 
virtual void on_new_task (const Task &task, const Task &goal)=0
 Called every time a new task is created. More...
 
virtual void on_new_reading (const Task &goal, const Task &currentTask)=0
 Called every time asensor reading is available. More...
 
virtual void init (const Task &goal)=0
 
virtual bool hasTaskEnded (Task &t)
 
void make_log ()
 opens file where all the data is dumped
 

Public Attributes

Threshold threshold =Threshold()
 

Protected Member Functions

void log_thresholds ()
 

Protected Attributes

friend Configurator
 
ThresholdLearnerlearner =NULL
 
b2Transform deltaTransform =b2Transform_zero
 

Detailed Description

Tracking interface: Bridge between the real world and the simulation. Is used for tracking execution of tasks and using lived experience to modify the state-matching threshold.

Member Function Documentation

◆ get_transform()

TrackingResult Tracker::get_transform ( const Task t,
const CoordinateContainer pts,
const std::vector< BodyFeatures > &  objects 
)
virtual

calculates 2d affine transformation of input task's disturbance from t-1 to t. In other words, expresses how much the disturbance has moved

Parameters
tinput task
ptspoint cloud
objectsworld objects as extracted in worldbuilder

Reimplemented in ClosedLoop_Tracker.

◆ on_new_reading()

virtual void Tracker::on_new_reading ( const Task goal,
const Task currentTask 
)
pure virtual

Called every time asensor reading is available.

Parameters
task

Implemented in ClosedLoop_Tracker, and DeadReckoner.

◆ on_new_task()

virtual void Tracker::on_new_task ( const Task task,
const Task goal 
)
pure virtual

Called every time a new task is created.

Parameters
tthe task

Implemented in ClosedLoop_Tracker, and DeadReckoner.

◆ track()

virtual TrackingResult Tracker::track ( const Task t,
const CoordinateContainer pts,
const std::vector< BodyFeatures > &  objects 
)
pure virtual

Tracks task execution.

Parameters
tinput task
ptspoint cloud
observed_disturbancepointer body features of the observed disturbance.
objectsworld objects as extracted in worldbuilder
Returns
b2Transform that the robot has moved by, can use for updating cognitive map and control

Implemented in ClosedLoop_Tracker, and DeadReckoner.


The documentation for this class was generated from the following files: