#3060 - Adding version to YAML files within PrimAITE
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
game:
|
||||
ports:
|
||||
- ARP
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
game:
|
||||
ports:
|
||||
- ARP
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
io_settings:
|
||||
save_agent_actions: true
|
||||
save_step_metadata: false
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
io_settings:
|
||||
save_agent_actions: true
|
||||
save_step_metadata: false
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
game:
|
||||
max_episode_length: 128
|
||||
ports: []
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
game:
|
||||
ports:
|
||||
- ARP
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
version: 3.0
|
||||
|
||||
io_settings:
|
||||
save_agent_actions: true
|
||||
save_step_metadata: false
|
||||
|
||||
@@ -247,6 +247,11 @@ class PrimaiteGame:
|
||||
game.options = PrimaiteGameOptions(**cfg["game"])
|
||||
game.save_step_metadata = cfg.get("io_settings", {}).get("save_step_metadata") or False
|
||||
|
||||
# TODO: Future YAML config should specify the PrimAITE version they are written for.
|
||||
# For now, we warn that if it is missing, pending a mechanism to handle variations.
|
||||
if not cfg["version"]:
|
||||
_LOGGER.warning("Version definition is missing from provided configuration. ")
|
||||
|
||||
# 1. create simulation
|
||||
sim = game.simulation
|
||||
net = sim.network
|
||||
|
||||
Reference in New Issue
Block a user