Antonio Serrano Muñoz commited on
Commit
37ec050
1 Parent(s): 9fa0f8f

Add README

Browse files
Files changed (1) hide show
  1. README.md +69 -0
README.md ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ library_name: skrl
3
+ tags:
4
+ - deep-reinforcement-learning
5
+ - reinforcement-learning
6
+ - skrl
7
+ model-index:
8
+ - name: PPO
9
+ results:
10
+ - metrics:
11
+ - type: mean_reward
12
+ value: 1106.75 +/- 63.75
13
+ name: Total reward (mean)
14
+ task:
15
+ type: reinforcement-learning
16
+ name: reinforcement-learning
17
+ dataset:
18
+ name: OmniIsaacGymEnvs-Crazyflie
19
+ type: OmniIsaacGymEnvs-Crazyflie
20
+ ---
21
+
22
+ # OmniIsaacGymEnvs-Crazyflie-PPO
23
+
24
+ Trained agent model for [NVIDIA Omniverse Isaac Gym](https://github.com/NVIDIA-Omniverse/OmniIsaacGymEnvs) environment
25
+
26
+ - **Task:** Crazyflie
27
+ - **Agent:** [PPO](https://skrl.readthedocs.io/en/latest/modules/skrl.agents.ppo.html)
28
+
29
+ # Usage (with skrl)
30
+
31
+ ```python
32
+ from skrl.utils.huggingface import download_model_from_huggingface
33
+
34
+ # assuming that there is an agent named `agent`
35
+ path = download_model_from_huggingface("skrl/OmniIsaacGymEnvs-Crazyflie-PPO")
36
+ agent.load(path)
37
+ ```
38
+
39
+ # Hyperparameters
40
+
41
+ ```python
42
+ # https://skrl.readthedocs.io/en/latest/modules/skrl.agents.ppo.html#configuration-and-hyperparameters
43
+ cfg_agent = PPO_DEFAULT_CONFIG.copy()
44
+ cfg_agent["rollouts"] = 16 # memory_size
45
+ cfg_agent["learning_epochs"] = 8
46
+ cfg_agent["mini_batches"] = 1 # 16 * 512 / 8192
47
+ cfg_agent["discount_factor"] = 0.99
48
+ cfg_agent["lambda"] = 0.95
49
+ cfg_agent["learning_rate"] = 3e-4
50
+ cfg_agent["learning_rate_scheduler"] = KLAdaptiveRL
51
+ cfg_agent["learning_rate_scheduler_kwargs"] = {"kl_threshold": 0.008}
52
+ cfg_agent["random_timesteps"] = 0
53
+ cfg_agent["learning_starts"] = 0
54
+ cfg_agent["grad_norm_clip"] = 1.0
55
+ cfg_agent["ratio_clip"] = 0.2
56
+ cfg_agent["value_clip"] = 0.2
57
+ cfg_agent["clip_predicted_values"] = True
58
+ cfg_agent["entropy_loss_scale"] = 0.0
59
+ cfg_agent["value_loss_scale"] = 2.0
60
+ cfg_agent["kl_threshold"] = 0
61
+ cfg_agent["rewards_shaper"] = lambda rewards, timestep, timesteps: rewards * 0.1
62
+ cfg_agent["state_preprocessor"] = RunningStandardScaler
63
+ cfg_agent["state_preprocessor_kwargs"] = {"size": env.observation_space, "device": device}
64
+ cfg_agent["value_preprocessor"] = RunningStandardScaler
65
+ cfg_agent["value_preprocessor_kwargs"] = {"size": 1, "device": device}
66
+ # logging to TensorBoard and writing checkpoints
67
+ cfg_agent["experiment"]["write_interval"] = 16
68
+ cfg_agent["experiment"]["checkpoint_interval"] = 80
69
+ ```