Skip to content

Commit

Permalink
Refactor simulation and robot configuration in demo_defensive.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ll7 committed Mar 7, 2024
1 parent cb05290 commit b40d840
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions demo_defensive.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,15 @@
from robot_sf.sim.sim_config import SimulationSettings
from robot_sf.robot.differential_drive import DifferentialDriveSettings

def training():
env_config = EnvSettings(
sim_config=SimulationSettings(stack_steps=1, difficulty=0, ped_density_by_difficulty=[0.06]),
robot_config=DifferentialDriveSettings(radius=1.0))
sim_config=SimulationSettings(
stack_steps=1,
difficulty=0,
ped_density_by_difficulty=[0.06]
),
robot_config=DifferentialDriveSettings(radius=1.0)
)
env = RobotEnv(env_config, debug=True)
env.observation_space, env.action_space = prepare_gym_spaces()
model = PPO.load("./model/run_023", env=env)
Expand Down

0 comments on commit b40d840

Please sign in to comment.