Skip to content

Commit 54dd3a5

Browse files
committed
AUTO-6393: Move SimulationSettings into lgsvl.wise
Move the SimulationSettings class into a new lsgvl.wise subpackage. Split off the variables for assets into a separate DefaultAssets class. Update the references as follows: SimulatorSettings.bridge_* -> lgsvl.wise.SimulatorSettings.bridge_* SimulatorSettings.simulator_* -> lgsvl.wise.SimulatorSettings.simulator_* SimulatorSettings.ego_* -> lgsvl.wise.DefaultAssets.ego_* SimulatorSettings.map_* -> lgsvl.wise.DefaultAssets.map_*
1 parent 979f5d4 commit 54dd3a5

File tree

78 files changed

+296
-359
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+296
-359
lines changed

.flake8

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,4 @@ per-file-ignores =
1212
lgsvl/__init__.py:F401
1313
lgsvl/dreamview/__init__.py:F401
1414
lgsvl/evaluator/__init__.py:F401
15+
lgsvl/wise/__init__.py:F401

examples/NHTSA/Encroaching-Oncoming-Vehicles/EOV_S_25_20.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -34,7 +33,7 @@
3433
print("EOV_S_25_20 - ", end='')
3534

3635
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
37-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2laneopposing)
36+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2laneopposing)
3837
if sim.current_scene == scene_name:
3938
sim.reset()
4039
else:
@@ -45,7 +44,7 @@
4544
# A point close to the desired lane was found in Editor.
4645
# This method returns the position and orientation of the closest lane to the point.
4746
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(-1.6, 0, -65))
48-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
47+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4948
forward = lgsvl.utils.transform_to_forward(egoState.transform)
5049
right = lgsvl.utils.transform_to_right(egoState.transform)
5150

examples/NHTSA/Encroaching-Oncoming-Vehicles/EOV_S_45_40.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -34,7 +33,7 @@
3433
print("EOV_S_45_40 - ", end='')
3534

3635
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
37-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2laneopposing)
36+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2laneopposing)
3837
if sim.current_scene == scene_name:
3938
sim.reset()
4039
else:
@@ -45,7 +44,7 @@
4544
# A point close to the desired lane was found in Editor.
4645
# This method returns the position and orientation of the closest lane to the point.
4746
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(-1.6, 0, -65))
48-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
47+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4948
forward = lgsvl.utils.transform_to_forward(egoState.transform)
5049
right = lgsvl.utils.transform_to_right(egoState.transform)
5150

examples/NHTSA/Encroaching-Oncoming-Vehicles/EOV_S_65_60.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -34,7 +33,7 @@
3433
print("EOV_S_65_60 - ", end='')
3534

3635
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
37-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2laneopposing)
36+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2laneopposing)
3837
if sim.current_scene == scene_name:
3938
sim.reset()
4039
else:
@@ -45,7 +44,7 @@
4544
# A point close to the desired lane was found in Editor.
4645
# This method returns the position and orientation of the closest lane to the point.
4746
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(-1.6, 0, -65))
48-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
47+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4948
forward = lgsvl.utils.transform_to_forward(egoState.transform)
5049
right = lgsvl.utils.transform_to_right(egoState.transform)
5150

examples/NHTSA/Move-Out-of-Travel-Lane/MOTL_Comp_15.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -32,7 +31,7 @@
3231
print("MOTL_Comp_15 - ", end='')
3332

3433
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
35-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2lanesamecurbrightintersection)
34+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2lanesamecurbrightintersection)
3635
if sim.current_scene == scene_name:
3736
sim.reset()
3837
else:
@@ -43,7 +42,7 @@
4342
# A point close to the desired lane was found in Editor.
4443
# This method returns the position and orientation of the closest lane to the point.
4544
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(2.6, 0, 30))
46-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
45+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4746
forward = lgsvl.utils.transform_to_forward(egoState.transform)
4847
right = lgsvl.utils.transform_to_right(egoState.transform)
4948

examples/NHTSA/Move-Out-of-Travel-Lane/MOTL_Comp_25.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -32,7 +31,7 @@
3231
print("MOTL_Comp_25 - ", end='')
3332

3433
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
35-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2lanesamecurbrightintersection)
34+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2lanesamecurbrightintersection)
3635
if sim.current_scene == scene_name:
3736
sim.reset()
3837
else:
@@ -43,7 +42,7 @@
4342
# A point close to the desired lane was found in Editor.
4443
# This method returns the position and orientation of the closest lane to the point.
4544
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(2.6, 0, 30))
46-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
45+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4746
forward = lgsvl.utils.transform_to_forward(egoState.transform)
4847
right = lgsvl.utils.transform_to_right(egoState.transform)
4948

examples/NHTSA/Move-Out-of-Travel-Lane/MOTL_Neg_15.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -32,7 +31,7 @@
3231
print("MOTL_Neg_15 - ", end='')
3332

3433
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
35-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2lanesamecurbrightintersection)
34+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2lanesamecurbrightintersection)
3635
if sim.current_scene == scene_name:
3736
sim.reset()
3837
else:
@@ -43,7 +42,7 @@
4342
# A point close to the desired lane was found in Editor.
4443
# This method returns the position and orientation of the closest lane to the point.
4544
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(2.6, 0, 30))
46-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
45+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4746
forward = lgsvl.utils.transform_to_forward(egoState.transform)
4847
right = lgsvl.utils.transform_to_right(egoState.transform)
4948

examples/NHTSA/Move-Out-of-Travel-Lane/MOTL_Neg_25.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -32,7 +31,7 @@
3231
print("MOTL_Neg_25 - ", end='')
3332

3433
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
35-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2lanesamecurbrightintersection)
34+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2lanesamecurbrightintersection)
3635
if sim.current_scene == scene_name:
3736
sim.reset()
3837
else:
@@ -43,7 +42,7 @@
4342
# A point close to the desired lane was found in Editor.
4443
# This method returns the position and orientation of the closest lane to the point.
4544
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(2.6, 0, 30))
46-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
45+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4746
forward = lgsvl.utils.transform_to_forward(egoState.transform)
4847
right = lgsvl.utils.transform_to_right(egoState.transform)
4948

examples/NHTSA/Move-Out-of-Travel-Lane/MOTL_Simp_15.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
import logging
1717
from environs import Env
1818
import lgsvl
19-
from settings import SimulatorSettings
2019

2120
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
2221
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -37,7 +36,7 @@
3736
print("MOTL_Simp_15 - ", end='')
3837

3938
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
40-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2lanesamecurbrightintersection)
39+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2lanesamecurbrightintersection)
4140
if sim.current_scene == scene_name:
4241
sim.reset()
4342
else:
@@ -48,7 +47,7 @@
4847
# A point close to the desired lane was found in Editor.
4948
# This method returns the position and orientation of the closest lane to the point.
5049
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(2.6, 0, 30))
51-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
50+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
5251
forward = lgsvl.utils.transform_to_forward(egoState.transform)
5352
right = lgsvl.utils.transform_to_right(egoState.transform)
5453

examples/NHTSA/Move-Out-of-Travel-Lane/MOTL_Simp_25.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import logging
1212
from environs import Env
1313
import lgsvl
14-
from settings import SimulatorSettings
1514

1615
FORMAT = "[%(levelname)6s] [%(name)s] %(message)s"
1716
logging.basicConfig(level=logging.WARNING, format=FORMAT)
@@ -32,7 +31,7 @@
3231
print("MOTL_Simp_25 - ", end='')
3332

3433
sim = lgsvl.Simulator(LGSVL__SIMULATOR_HOST, LGSVL__SIMULATOR_PORT)
35-
scene_name = env.str("LGSVL__MAP", SimulatorSettings.map_straight2lanesamecurbrightintersection)
34+
scene_name = env.str("LGSVL__MAP", lgsvl.wise.DefaultAssets.map_straight2lanesamecurbrightintersection)
3635
if sim.current_scene == scene_name:
3736
sim.reset()
3837
else:
@@ -43,7 +42,7 @@
4342
# A point close to the desired lane was found in Editor.
4443
# This method returns the position and orientation of the closest lane to the point.
4544
egoState.transform = sim.map_point_on_lane(lgsvl.Vector(2.6, 0, 30))
46-
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", SimulatorSettings.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
45+
ego = sim.add_agent(env.str("LGSVL__VEHICLE_0", lgsvl.wise.DefaultAssets.ego_lincoln2017mkz_apollo5_full_analysis), lgsvl.AgentType.EGO, egoState)
4746
forward = lgsvl.utils.transform_to_forward(egoState.transform)
4847
right = lgsvl.utils.transform_to_right(egoState.transform)
4948

0 commit comments

Comments
 (0)