Class POMDPCoverageRobot

Inheritance Relationships

Base Type

Derived Types

Class Documentation

class POMDPCoverageRobot : public CoverageRobot

A class for a coverage robot which uses the POMDP planner.

Members: As in superclass, plus:

  • _exec: The IMac executor capturing the evolution of the environment

  • _fov: The robot’s field of view

  • _latestObs: The robot’s latest observation

  • _planner: The coverage planner

  • _pomdp: The coverage planning model

  • _world: The world object which wraps around exec

  • _solver: The DESPOT solver

  • _boundType: The type of bounds to use in DESPOT

  • _pruningConstant: The DESPOT pruning constant

  • _numScenarios: The number of scenarios to simulate in DESPOT

Subclassed by BoustrophedonCoverageRobot, EnergyFunctionalCoverageRobot, GreedyCoverageRobot

Public Functions

inline POMDPCoverageRobot(const GridCell &currentLoc, int timeBound, int xDim, int yDim, const std::vector<GridCell> &fov, std::shared_ptr<IMacExecutor> exec, std::shared_ptr<IMac> groundTruthIMac = nullptr, const ParameterEstimate &estimationType = ParameterEstimate::posteriorSample, std::string boundType = "DEFAULT", const double &pruningConstant = 0.1, const int &numScenarios = 500)

Constructor calls super constructor and initialises new members.

Parameters:
  • currentLoc – The robot’s current location

  • timeBound – The planning time bound

  • xDim – The x dimension of the map

  • yDim – The y dimension of the map

  • exec – The IMacExecutor representing the environment

  • fov – The robot’s FOV as a vector of relative grid cells

  • groundTruthIMac – The ground truth IMac instance (if we don’t want to use BiMac)

  • estimationType – The type of parameter estimation to use for IMac instance for episode

  • boundType – The type of upper and lower bounds to use

  • pruningConstant – The DESPOT pruning constant

  • numScenarios – The number of simulated scenarios in DESPOT

inline ~POMDPCoverageRobot()

Ensures everything is cleaned up on object deletion. episodeCleanup will only deallocate if not nullptrs.

virtual void episodeSetup(const GridCell &startLoc, const int &ts, const int &timeBound, std::shared_ptr<IMac> imacForEpisode)

Runs necessary setup for creating the POMDP planner.

Parameters:
  • startLoc – The robot’s initial location for the episode

  • ts – The initial timestep

  • timeBound – The episode time bound, which could change

  • imacForEpisode – The IMac instance being used for the planning episode

virtual void episodeCleanup()

Deallocates objects used by the CoveragePlanner object.

Protected Functions

virtual Action _planFn(const GridCell &currentLoc, const std::vector<Action> &enabledActions, int ts, int timeBound, std::shared_ptr<IMac> imac, const std::vector<GridCell> &visited, const std::vector<IMacObservation> &currentObs)

Synthesises an action using the POMDP planner Recall that x goes from left to right, y from top to bottom.

Parameters:
  • currentLoc – The robot’s current location

  • enabledActions – A vector of enabled actions in this state

  • ts – The current timestep

  • timeBound – The time bound

  • imac – The current IMac instance

  • visited – The vector of visited locations

  • currentObs – The most recent observations

Returns:

The next action to be executed

Protected Attributes

CoverageBelief *_belief = {}