未验证 提交 450a4a34 编写于 作者: B Bo Zhou 提交者: GitHub

fix paddle version bug (#207)

* fix paddle version bug

* add gym dependence (introduced by MADDPG)

* recall
上级 bbcb707b
# Copyright (c) 2018 PaddlePaddle Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import os
import re
def update(fname, ver):
with open(fname, 'r') as f:
lines = f.readlines()
for i, line in enumerate(lines):
if 'paddlepaddle>=' in line:
lines[i] = re.sub("paddlepaddle>=[\d+\.]+",
"paddlepaddle>={}".format(ver), line)
with open(fname, 'w') as f:
for line in lines:
f.write(line)
if __name__ == '__main__':
new_version = '1.6.1'
readme_files = ['../README.md', '../README.cn.md']
exclude_examples = [
'NeurIPS2019-Learn-to-Move-Challenge',
'NeurIPS2018-AI-for-Prosthetics-Challenge', 'EagerMode'
]
for example in os.listdir('../examples/'):
if example not in exclude_examples:
readme_files.append(
os.path.join('../examples', example, 'README.md'))
for example in os.listdir('../examples/EagerMode/'):
readme_files.append(
os.path.join('../examples/EagerMode', example, 'README.md'))
print(readme_files)
for fname in readme_files:
update(fname, new_version)
...@@ -62,7 +62,7 @@ ans = agent.sum(1,5) # run remotely and not comsume any local computation resour ...@@ -62,7 +62,7 @@ ans = agent.sum(1,5) # run remotely and not comsume any local computation resour
# 安装: # 安装:
### 依赖 ### 依赖
- Python 2.7 or 3.5+. - Python 2.7 or 3.5+.
- [PaddlePaddle](https://github.com/PaddlePaddle/Paddle) >=1.2.1 (**非必须的**,如果你只用并行部分的接口不需要安装paddle) - [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle) (**非必须的**,如果你只用并行部分的接口不需要安装paddle)
``` ```
......
...@@ -65,7 +65,7 @@ For users, they can write code in a simple way, just like writing multi-thread c ...@@ -65,7 +65,7 @@ For users, they can write code in a simple way, just like writing multi-thread c
# Install: # Install:
### Dependencies ### Dependencies
- Python 2.7 or 3.5+. - Python 2.7 or 3.5+.
- [PaddlePaddle](https://github.com/PaddlePaddle/Paddle) >=1.5.1 (**Optional**, if you only want to use APIs related to parallelization alone) - [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle) (**Optional**, if you only want to use APIs related to parallelization alone)
``` ```
......
...@@ -19,7 +19,7 @@ Performance of A2C on various envrionments ...@@ -19,7 +19,7 @@ Performance of A2C on various envrionments
## How to use ## How to use
### Dependencies ### Dependencies
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym==0.12.1 + gym==0.12.1
+ atari-py==0.1.7 + atari-py==0.1.7
......
...@@ -15,7 +15,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco ...@@ -15,7 +15,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco
## How to use ## How to use
### Dependencies: ### Dependencies:
+ python3.5+ + python3.5+
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
+ tqdm + tqdm
......
...@@ -21,7 +21,7 @@ Performance of DQN on various environments ...@@ -21,7 +21,7 @@ Performance of DQN on various environments
## How to use ## How to use
### Dependencies: ### Dependencies:
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
+ tqdm + tqdm
......
...@@ -12,7 +12,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco ...@@ -12,7 +12,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco
## How to use ## How to use
### Dependencies ### Dependencies
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym==0.9.4 + gym==0.9.4
+ mujoco-py==0.5.1 + mujoco-py==0.5.1
......
...@@ -4,7 +4,7 @@ Train an agent with PARL to solve the CartPole problem, a classical benchmark in ...@@ -4,7 +4,7 @@ Train an agent with PARL to solve the CartPole problem, a classical benchmark in
## How to use ## How to use
### Dependencies: ### Dependencies:
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
......
...@@ -16,7 +16,7 @@ Results with one learner (in a P40 GPU) and 24 simulators (in 12 CPU) in 10 mill ...@@ -16,7 +16,7 @@ Results with one learner (in a P40 GPU) and 24 simulators (in 12 CPU) in 10 mill
## How to use ## How to use
### Dependencies ### Dependencies
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym==0.12.1 + gym==0.12.1
+ atari-py==0.1.7 + atari-py==0.1.7
......
...@@ -20,7 +20,7 @@ Result with one learner (in a P40 GPU) and 32 actors (in 32 CPUs). ...@@ -20,7 +20,7 @@ Result with one learner (in a P40 GPU) and 32 actors (in 32 CPUs).
## How to use ## How to use
### Dependencies ### Dependencies
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym==0.12.1 + gym==0.12.1
+ atari-py==0.1.7 + atari-py==0.1.7
......
...@@ -95,7 +95,7 @@ simple_world_comm<br> ...@@ -95,7 +95,7 @@ simple_world_comm<br>
## How to use ## How to use
### Dependencies: ### Dependencies:
+ python3.5+ + python3.5+
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ [multiagent-particle-envs](https://github.com/openai/multiagent-particle-envs) + [multiagent-particle-envs](https://github.com/openai/multiagent-particle-envs)
+ gym + gym
......
...@@ -19,6 +19,7 @@ For more technical details about our solution, we provide: ...@@ -19,6 +19,7 @@ For more technical details about our solution, we provide:
## Dependencies ## Dependencies
- python3.6 - python3.6
- [parl==1.0](https://github.com/PaddlePaddle/PARL)
- [paddlepaddle==1.5.1](https://github.com/PaddlePaddle/Paddle) - [paddlepaddle==1.5.1](https://github.com/PaddlePaddle/Paddle)
- [osim-rl](https://github.com/stanfordnmbl/osim-rl) - [osim-rl](https://github.com/stanfordnmbl/osim-rl)
- [grpcio==1.12.1](https://grpc.io/docs/quickstart/python.html) - [grpcio==1.12.1](https://grpc.io/docs/quickstart/python.html)
......
...@@ -6,6 +6,7 @@ The **PARL** team gets the first place in NeurIPS reinforcement learning competi ...@@ -6,6 +6,7 @@ The **PARL** team gets the first place in NeurIPS reinforcement learning competi
## Dependencies ## Dependencies
- python3.6 - python3.6
- [parl==1.2.1](https://github.com/PaddlePaddle/PARL)
- [paddlepaddle==1.5.1](https://github.com/PaddlePaddle/Paddle) - [paddlepaddle==1.5.1](https://github.com/PaddlePaddle/Paddle)
- [parl>=1.2.1](https://github.com/PaddlePaddle/PARL) - [parl>=1.2.1](https://github.com/PaddlePaddle/PARL)
- [osim-rl==3.0.11](https://github.com/stanfordnmbl/osim-rl) - [osim-rl==3.0.11](https://github.com/stanfordnmbl/osim-rl)
......
...@@ -18,7 +18,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco ...@@ -18,7 +18,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco
## How to use ## How to use
### Dependencies: ### Dependencies:
+ python3.5+ + python3.5+
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
+ tqdm + tqdm
......
...@@ -4,7 +4,7 @@ Train an agent with PARL to solve the CartPole problem, a classical benchmark in ...@@ -4,7 +4,7 @@ Train an agent with PARL to solve the CartPole problem, a classical benchmark in
## How to use ## How to use
### Dependencies: ### Dependencies:
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
......
...@@ -18,7 +18,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco ...@@ -18,7 +18,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco
## How to use ## How to use
### Dependencies: ### Dependencies:
+ python3.5+ + python3.5+
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
+ mujoco-py>=1.50.1.0 + mujoco-py>=1.50.1.0
......
...@@ -19,7 +19,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco ...@@ -19,7 +19,7 @@ Please see [here](https://github.com/openai/mujoco-py) to know more about Mujoco
## How to use ## How to use
### Dependencies: ### Dependencies:
+ python3.5+ + python3.5+
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
+ mujoco-py>=1.50.1.0 + mujoco-py>=1.50.1.0
......
...@@ -21,7 +21,7 @@ learn_program = parl.compile(learn_program, loss=training_loss) ...@@ -21,7 +21,7 @@ learn_program = parl.compile(learn_program, loss=training_loss)
We provide a demonstration of offline Q-learning with parallel executing, in which we seperate the procedures of collecting data and training the model. First we collect data by interacting with the environment and save them to a replay memory file, and then fit and evaluate the Q network with the collected data. Repeat these two steps to improve the performance gradually. We provide a demonstration of offline Q-learning with parallel executing, in which we seperate the procedures of collecting data and training the model. First we collect data by interacting with the environment and save them to a replay memory file, and then fit and evaluate the Q network with the collected data. Repeat these two steps to improve the performance gradually.
### Dependencies: ### Dependencies:
+ [paddlepaddle>=1.5.1](https://github.com/PaddlePaddle/Paddle) + [paddlepaddle>=1.6.1](https://github.com/PaddlePaddle/Paddle)
+ [parl](https://github.com/PaddlePaddle/PARL) + [parl](https://github.com/PaddlePaddle/PARL)
+ gym + gym
+ tqdm + tqdm
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册