Skip to content

Commit 3de398a

Browse files
committed
Make sensor range optional with default 0.5
1 parent 35e2064 commit 3de398a

8 files changed

+10
-10
lines changed

config/level0.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ id = "DroneRacing-v0" # "DroneRacing-v0" for single races, "MultiDroneRacing-v
3232
random_resets = false # Whether to re-seed the random number generator between episodes
3333
seed = 1337 # Random seed
3434
freq = 50 # Frequency of the environment's step function, in Hz
35-
sensor_range = 0.45 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
35+
sensor_range = 0.5 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
3636
action_space = "state" # Action space of the environment. Can be either "state" or "attitude"
3737

3838
[env.track]

config/level1.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ id = "DroneRacing-v0" # "DroneRacing-v0" for single races, "MultiDroneRacing-v
2828
random_resets = false # Whether to re-seed the random number generator between episodes
2929
seed = 1337 # Random seed
3030
freq = 50 # Frequency of the environment's step function, in Hz
31-
sensor_range = 0.45 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
31+
sensor_range = 0.5 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
3232
action_space = "state" # Action space of the environment. Can be either "state" or "attitude"
3333

3434
[env.track]

config/level2.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ id = "DroneRacing-v0" # "DroneRacing-v0" for single races, "MultiDroneRacing-v
2828
random_resets = false # Whether to re-seed the random number generator between episodes
2929
seed = 1337 # Random seed
3030
freq = 50 # Frequency of the environment's step function, in Hz
31-
sensor_range = 0.45 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
31+
sensor_range = 0.5 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
3232
action_space = "state" # Action space of the environment. Can be either "state" or "attitude"
3333

3434
[env.track]

config/level3.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ id = "DroneRacing-v0" # "DroneRacing-v0" for single races, "MultiDroneRacing-v
2828
random_resets = true # Whether to re-seed the random number generator between episodes
2929
seed = 1337 # Random seed
3030
freq = 50 # Frequency of the environment's step function, in Hz
31-
sensor_range = 0.45 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
31+
sensor_range = 0.5 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
3232
action_space = "state" # Action space of the environment. Can be either "state" or "attitude"
3333

3434
[env.track]

config/multi_level0.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ n_drones = 2 # Number of drones has to match the track configuration
3333
random_resets = false # Whether to re-seed the random number generator between episodes
3434
seed = 1337 # Random seed
3535
freq = 50 # Frequency of the environment's step function, in Hz
36-
sensor_range = 0.45 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
36+
sensor_range = 0.5 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
3737
action_space = "state" # Action space of the environment. Can be either "state" or "attitude"
3838

3939
[env.track]

config/multi_level3.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ n_drones = 2 # Number of drones has to match the track configuration
3333
random_resets = true # Whether to re-seed the random number generator between episodes
3434
seed = 1337 # Random seed
3535
freq = 50 # Frequency of the environment's step function, in Hz
36-
sensor_range = 0.45 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
36+
sensor_range = 0.5 # Range at which the exact location of gates and obstacles become visible to the drone. Objects that are not in the drone's sensor range report their nominal position.
3737
action_space = "state" # Action space of the environment. Can be either "state" or "attitude"
3838

3939
[env.track]

lsy_drone_racing/envs/drone_race.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def __init__(
2323
self,
2424
freq: int,
2525
sim_config: ConfigDict,
26-
sensor_range: float,
26+
sensor_range: float = 0.5,
2727
action_space: Literal["state", "attitude"] = "state",
2828
track: ConfigDict | None = None,
2929
disturbances: ConfigDict | None = None,
@@ -106,7 +106,7 @@ def __init__(
106106
num_envs: int,
107107
freq: int,
108108
sim_config: ConfigDict,
109-
sensor_range: float,
109+
sensor_range: float = 0.5,
110110
action_space: Literal["state", "attitude"] = "state",
111111
track: ConfigDict | None = None,
112112
disturbances: ConfigDict | None = None,

lsy_drone_racing/envs/multi_drone_race.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def __init__(
2424
n_drones: int,
2525
freq: int,
2626
sim_config: ConfigDict,
27-
sensor_range: float,
27+
sensor_range: float = 0.5,
2828
action_space: Literal["state", "attitude"] = "state",
2929
track: ConfigDict | None = None,
3030
disturbances: ConfigDict | None = None,
@@ -116,7 +116,7 @@ def __init__(
116116
n_drones: int,
117117
freq: int,
118118
sim_config: ConfigDict,
119-
sensor_range: float,
119+
sensor_range: float = 0.5,
120120
action_space: Literal["state", "attitude"] = "state",
121121
track: ConfigDict | None = None,
122122
disturbances: ConfigDict | None = None,

0 commit comments

Comments
 (0)