gym-examples 2.0.110__py3-none-any.whl → 2.0.112__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- gym_examples/__init__.py +1 -1
- gym_examples/envs/wsn_env.py +1 -1
- {gym_examples-2.0.110.dist-info → gym_examples-2.0.112.dist-info}/METADATA +1 -1
- gym_examples-2.0.112.dist-info/RECORD +7 -0
- gym_examples-2.0.110.dist-info/RECORD +0 -7
- {gym_examples-2.0.110.dist-info → gym_examples-2.0.112.dist-info}/WHEEL +0 -0
- {gym_examples-2.0.110.dist-info → gym_examples-2.0.112.dist-info}/top_level.txt +0 -0
gym_examples/__init__.py
CHANGED
gym_examples/envs/wsn_env.py
CHANGED
@@ -134,7 +134,7 @@ class WSNRoutingEnv(gym.Env):
|
|
134
134
|
# final_reward = net(rewards_individual)
|
135
135
|
# self.rewards_individual[i] = rewards[i]
|
136
136
|
# final_reward = np.sum(rewards[i])
|
137
|
-
weights =
|
137
|
+
weights = np.ones(self.n_sensors, dtype=int)
|
138
138
|
final_reward = np.sum(reward * weight for reward, weight in zip(rewards[i], weights))
|
139
139
|
rewards[i] = final_reward
|
140
140
|
# rewards = [0.5 * r + 0.5 * (1/self.n_sensors) * (self.network_reward_consumption_energy() + self.network_reward_dispersion_remaining_energy()) for r in rewards]
|
@@ -0,0 +1,7 @@
|
|
1
|
+
gym_examples/__init__.py,sha256=Gm4cUuKdsDEOtZpk-EVIsaHkgyz4zpEx7tIplA3iBQM,194
|
2
|
+
gym_examples/envs/__init__.py,sha256=lgMe4pyOuUTgTBUddM0iwMlETsYTwFShny6ifm8PGM8,53
|
3
|
+
gym_examples/envs/wsn_env.py,sha256=tKtJm5wgDexkeHrrj7VzXC_cb5Ajq-pCI_VNGLQ6SLg,17380
|
4
|
+
gym_examples-2.0.112.dist-info/METADATA,sha256=QTFAB99uNMpPcBj9soJPeFQOR8u-KNcurfx8YIFrZqk,412
|
5
|
+
gym_examples-2.0.112.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
6
|
+
gym_examples-2.0.112.dist-info/top_level.txt,sha256=rJRksoAF32M6lTLBEwYzRdo4PgtejceaNnnZ3HeY_Rk,13
|
7
|
+
gym_examples-2.0.112.dist-info/RECORD,,
|
@@ -1,7 +0,0 @@
|
|
1
|
-
gym_examples/__init__.py,sha256=gH2T-ct0Hi6ezm9VcLdPSPAphqvJ4BDGynuVTjyBDeo,194
|
2
|
-
gym_examples/envs/__init__.py,sha256=lgMe4pyOuUTgTBUddM0iwMlETsYTwFShny6ifm8PGM8,53
|
3
|
-
gym_examples/envs/wsn_env.py,sha256=PcTXkRFBNNM2SbIL61TY84dJtMHwxg8J-YeZZBD8YtU,17366
|
4
|
-
gym_examples-2.0.110.dist-info/METADATA,sha256=EM4ein8vHpfOgDM_KkeS5qIW-a2zyAkXc_3sxJWxOL4,412
|
5
|
-
gym_examples-2.0.110.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
6
|
-
gym_examples-2.0.110.dist-info/top_level.txt,sha256=rJRksoAF32M6lTLBEwYzRdo4PgtejceaNnnZ3HeY_Rk,13
|
7
|
-
gym_examples-2.0.110.dist-info/RECORD,,
|
File without changes
|
File without changes
|