Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -21,7 +21,7 @@ model-index:
|
|
| 21 |
type: OpenAI/Gym/Box2d-BipedalWalker-v3
|
| 22 |
metrics:
|
| 23 |
- type: mean_reward
|
| 24 |
-
value:
|
| 25 |
name: mean_reward
|
| 26 |
---
|
| 27 |
|
|
@@ -67,10 +67,10 @@ import torch
|
|
| 67 |
|
| 68 |
# Pull model from files which are git cloned from huggingface
|
| 69 |
policy_state_dict = torch.load("pytorch_model.bin", map_location=torch.device("cpu"))
|
| 70 |
-
cfg = EasyDict(Config.file_to_dict("policy_config.py"))
|
| 71 |
# Instantiate the agent
|
| 72 |
agent = TD3Agent(
|
| 73 |
-
|
| 74 |
)
|
| 75 |
# Continue training
|
| 76 |
agent.train(step=5000)
|
|
@@ -98,7 +98,7 @@ from huggingface_ding import pull_model_from_hub
|
|
| 98 |
policy_state_dict, cfg = pull_model_from_hub(repo_id="OpenDILabCommunity/BipedalWalker-v3-TD3")
|
| 99 |
# Instantiate the agent
|
| 100 |
agent = TD3Agent(
|
| 101 |
-
|
| 102 |
exp_name="BipedalWalker-v3-TD3",
|
| 103 |
cfg=cfg.exp_config,
|
| 104 |
policy_state_dict=policy_state_dict
|
|
@@ -128,7 +128,7 @@ from ding.bonus import TD3Agent
|
|
| 128 |
from huggingface_ding import push_model_to_hub
|
| 129 |
|
| 130 |
# Instantiate the agent
|
| 131 |
-
agent = TD3Agent("
|
| 132 |
# Train the agent
|
| 133 |
return_ = agent.train(step=int(200000))
|
| 134 |
# Push model to huggingface hub
|
|
@@ -145,7 +145,8 @@ push_model_to_hub(
|
|
| 145 |
usage_file_by_git_clone="./td3/bipedalwalker_td3_deploy.py",
|
| 146 |
usage_file_by_huggingface_ding="./td3/bipedalwalker_td3_download.py",
|
| 147 |
train_file="./td3/bipedalwalker_td3.py",
|
| 148 |
-
repo_id="OpenDILabCommunity/BipedalWalker-v3-TD3"
|
|
|
|
| 149 |
)
|
| 150 |
|
| 151 |
```
|
|
@@ -229,6 +230,7 @@ exp_config = {
|
|
| 229 |
'render_freq': -1,
|
| 230 |
'mode': 'train_iter'
|
| 231 |
},
|
|
|
|
| 232 |
'cfg_type': 'InteractionSerialEvaluatorDict',
|
| 233 |
'stop_value': 10000000000,
|
| 234 |
'n_episode': 5
|
|
@@ -270,7 +272,7 @@ exp_config = {
|
|
| 270 |
|
| 271 |
**Training Procedure**
|
| 272 |
<!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
|
| 273 |
-
- **Weights & Biases (wandb):** [monitor link](https://wandb.ai/
|
| 274 |
|
| 275 |
## Model Information
|
| 276 |
<!-- Provide the basic links for the model. -->
|
|
@@ -279,14 +281,14 @@ exp_config = {
|
|
| 279 |
- **Configuration:** [config link](https://huggingface.co/OpenDILabCommunity/BipedalWalker-v3-TD3/blob/main/policy_config.py)
|
| 280 |
- **Demo:** [video](https://huggingface.co/OpenDILabCommunity/BipedalWalker-v3-TD3/blob/main/replay.mp4)
|
| 281 |
<!-- Provide the size information for the model. -->
|
| 282 |
-
- **Parameters total size:**
|
| 283 |
-
- **Last Update Date:** 2023-
|
| 284 |
|
| 285 |
## Environments
|
| 286 |
<!-- Address questions around what environment the model is intended to be trained and deployed at, including the necessary information needed to be provided for future users. -->
|
| 287 |
- **Benchmark:** OpenAI/Gym/Box2d
|
| 288 |
- **Task:** BipedalWalker-v3
|
| 289 |
- **Gym version:** 0.25.1
|
| 290 |
-
- **DI-engine version:** v0.4.
|
| 291 |
-
- **PyTorch version:**
|
| 292 |
- **Doc**: [DI-engine-docs Environments link](https://di-engine-docs.readthedocs.io/en/latest/13_envs/bipedalwalker.html)
|
|
|
|
| 21 |
type: OpenAI/Gym/Box2d-BipedalWalker-v3
|
| 22 |
metrics:
|
| 23 |
- type: mean_reward
|
| 24 |
+
value: 320.88 +/- 0.56
|
| 25 |
name: mean_reward
|
| 26 |
---
|
| 27 |
|
|
|
|
| 67 |
|
| 68 |
# Pull model from files which are git cloned from huggingface
|
| 69 |
policy_state_dict = torch.load("pytorch_model.bin", map_location=torch.device("cpu"))
|
| 70 |
+
cfg = EasyDict(Config.file_to_dict("policy_config.py").cfg_dict)
|
| 71 |
# Instantiate the agent
|
| 72 |
agent = TD3Agent(
|
| 73 |
+
env_id="BipedalWalker-v3", exp_name="BipedalWalker-v3-TD3", cfg=cfg.exp_config, policy_state_dict=policy_state_dict
|
| 74 |
)
|
| 75 |
# Continue training
|
| 76 |
agent.train(step=5000)
|
|
|
|
| 98 |
policy_state_dict, cfg = pull_model_from_hub(repo_id="OpenDILabCommunity/BipedalWalker-v3-TD3")
|
| 99 |
# Instantiate the agent
|
| 100 |
agent = TD3Agent(
|
| 101 |
+
env_id="BipedalWalker-v3",
|
| 102 |
exp_name="BipedalWalker-v3-TD3",
|
| 103 |
cfg=cfg.exp_config,
|
| 104 |
policy_state_dict=policy_state_dict
|
|
|
|
| 128 |
from huggingface_ding import push_model_to_hub
|
| 129 |
|
| 130 |
# Instantiate the agent
|
| 131 |
+
agent = TD3Agent(env_id="BipedalWalker-v3", exp_name="BipedalWalker-v3-TD3")
|
| 132 |
# Train the agent
|
| 133 |
return_ = agent.train(step=int(200000))
|
| 134 |
# Push model to huggingface hub
|
|
|
|
| 145 |
usage_file_by_git_clone="./td3/bipedalwalker_td3_deploy.py",
|
| 146 |
usage_file_by_huggingface_ding="./td3/bipedalwalker_td3_download.py",
|
| 147 |
train_file="./td3/bipedalwalker_td3.py",
|
| 148 |
+
repo_id="OpenDILabCommunity/BipedalWalker-v3-TD3",
|
| 149 |
+
create_repo=False
|
| 150 |
)
|
| 151 |
|
| 152 |
```
|
|
|
|
| 230 |
'render_freq': -1,
|
| 231 |
'mode': 'train_iter'
|
| 232 |
},
|
| 233 |
+
'figure_path': None,
|
| 234 |
'cfg_type': 'InteractionSerialEvaluatorDict',
|
| 235 |
'stop_value': 10000000000,
|
| 236 |
'n_episode': 5
|
|
|
|
| 272 |
|
| 273 |
**Training Procedure**
|
| 274 |
<!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
|
| 275 |
+
- **Weights & Biases (wandb):** [monitor link](https://wandb.ai/zjowowen/BipedalWalker-v3-TD3)
|
| 276 |
|
| 277 |
## Model Information
|
| 278 |
<!-- Provide the basic links for the model. -->
|
|
|
|
| 281 |
- **Configuration:** [config link](https://huggingface.co/OpenDILabCommunity/BipedalWalker-v3-TD3/blob/main/policy_config.py)
|
| 282 |
- **Demo:** [video](https://huggingface.co/OpenDILabCommunity/BipedalWalker-v3-TD3/blob/main/replay.mp4)
|
| 283 |
<!-- Provide the size information for the model. -->
|
| 284 |
+
- **Parameters total size:** 4037.55 KB
|
| 285 |
+
- **Last Update Date:** 2023-09-22
|
| 286 |
|
| 287 |
## Environments
|
| 288 |
<!-- Address questions around what environment the model is intended to be trained and deployed at, including the necessary information needed to be provided for future users. -->
|
| 289 |
- **Benchmark:** OpenAI/Gym/Box2d
|
| 290 |
- **Task:** BipedalWalker-v3
|
| 291 |
- **Gym version:** 0.25.1
|
| 292 |
+
- **DI-engine version:** v0.4.9
|
| 293 |
+
- **PyTorch version:** 2.0.1+cu117
|
| 294 |
- **Doc**: [DI-engine-docs Environments link](https://di-engine-docs.readthedocs.io/en/latest/13_envs/bipedalwalker.html)
|