matrx_visualizer.visualization_server
¶
Module Contents¶
-
human_agent_view
(id)¶ Route for HumanAgentBrain
- Parameters
- id
The human agent ID. Is obtained from the URL.
- Returns
- str
The template for this agent’s view.
-
agent_view
(id)¶ Route for AgentBrain
- Parameters
- id
The agent ID. Is obtained from the URL.
- Returns
- str
The template for this agent’s view.
-
god_view
()¶ Route for the ‘god’ view which contains the ground truth of the world without restrictions.
- Returns
- str
The template for this view.
-
start_view
()¶ Route for the ‘start’ view which shows information about the current scenario, including links to all agents.
- Returns
- str
The template for this view.
-
shutdown
()¶ Shuts down the visualizer by stopping the Flask thread
- Returns
True
-
external_media
(filename)¶ Facilitate the use of images in the visualization outside of the static folder
- Parameters
- filename
path to the image file in the external media folder of the user.
- Returns
- Returns the url (relative from the website root) to that file
-
run_matrx_visualizer
(verbose, media_folder)¶ Creates a seperate Python thread in which the visualization server (Flask) is started, serving the JS visualization :return: MATRX visualization Python thread