model.perceptionhandler module

Module that holds classes that represent an agent’s perception handler.

class model.perceptionhandler.BasicPerceptionHandler

Bases: model.perceptionhandler.PerceptionHandler

A perception handler that perceives walls and blocks up to a given distance. The perception indicates the type of structure that is seen, as well as its distance.

perceive(agent_, world_)
class model.perceptionhandler.EmptyPerceptionHandler

Bases: model.perceptionhandler.PerceptionHandler

A trivial perception handler that never perceives anything.

perceive(agent, world)
class model.perceptionhandler.PerceptionHandler

Bases: object

Abstract perception handler class.

perceive(agent, world)

Generates a percept given an agent and a world.

Parameters:
  • agent – The agent to generate the percept for.
  • world – The world to generate the percept for.
Returns:

The percept.

class model.perceptionhandler.PersistentPerceptionHandler

Bases: model.perceptionhandler.PerceptionHandler

A perception handler that has a persistent perception. Perceives changes in the line of sight: objects that appeared, got closer, further away, etc.

perceive(agent_, world_)