specless.factory.tspbuilder.TSPWithTPOBuilder
- class specless.factory.tspbuilder.TSPWithTPOBuilder[source]
Bases:
TSPBuilder
Converts Transition System To a TSP Problem
Methods
add_initial_state
build_mappings_from_ts
convert_global_constraints
convert_local_constraints
Convert the original TPO whose nodes are labeled with the observation names to a TPO with numbered nodes that correspond to the TSP problem.
get_all_pair_shortest_paths
reads in the object configuration parameters from a YAML config file
map_back_to_controls
node_list_to_edges
synthesize_strategy
Attributes
TS States to Observations
Observation to Multiple TS States
Observation to Multiple TSP Nodes
TS States to TSP Nodes bidict
all pair shortest paths
- T: MinigridTransitionSystem | None
TS States to Observations
- __call__(T: MinigridTransitionSystem, specification: TimedPartialOrder, **kwargs) TSPWithTPO [source]
Translate a MiniGrid Transition System to a TSP with
- Returns:
_description_
- Return type:
_type_
- convert_tpo(tpo: TimedPartialOrder) TimedPartialOrder [source]
Convert the original TPO whose nodes are labeled with the observation names to a TPO with numbered nodes that correspond to the TSP problem.
- Parameters:
tpo (TimedPartialOrder) – _description_
- Returns:
_description_
- Return type:
- static load_YAML_config_data(config_file_name: str) dict
reads in the object configuration parameters from a YAML config file
- Parameters:
config_file_name ((filepath) string) – The YAML configuration file name
- Returns:
configuration data dictionary for the simulation
- Return type:
dict
- obs_to_nodes: Dict[str, List[int]]
TS States to TSP Nodes bidict
- obs_to_states: Dict[str, List[Tuple]]
Observation to Multiple TSP Nodes
- state_to_node: Dict[Tuple, int]
all pair shortest paths
- state_to_obs: Dict[Tuple, str]
Observation to Multiple TS States