lambders / drl-experiments Goto Github PK
View Code? Open in Web Editor NEWTraining a DRL agent to play Flappy Bird. An exercise to reimplement DQN, A2C, and PPO DRL methods.
Training a DRL agent to play Flappy Bird. An exercise to reimplement DQN, A2C, and PPO DRL methods.
Could you tell me the version of your pytorch. I got runtime error:
python main.py --algo=ppo --mode=train
pygame 1.9.6
Hello from the pygame community. https://www.pygame.org/contribute.html
/workdata/git/drl-experiments/ppo.py:54: UserWarning: nn.init.uniform is now deprecated in favor of nn.init.uniform_.
torch.nn.init.uniform(m.weight, -0.01, 0.01)
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: cHRM chunk does not match sRGB
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
Traceback (most recent call last):
File "main.py", line 133, in
agent.train()
File "/workdata/git/drl-experiments/ppo.py", line 241, in train
values, actions, action_log_probs = self.net.act(states)
File "/workdata/git/drl-experiments/ppo.py", line 87, in act
values, action_logits = self.forward(x)
File "/workdata/git/drl-experiments/ppo.py", line 72, in forward
x = self.relu1(self.conv1(x))
File "/home/minshi/.virtualenvs/drl-experiments-0ZyJdSJ6/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/minshi/.virtualenvs/drl-experiments-0ZyJdSJ6/lib/python3.6/site-packages/torch/nn/modules/conv.py", line 345, in forward
return self.conv2d_forward(input, self.weight)
File "/home/minshi/.virtualenvs/drl-experiments-0ZyJdSJ6/lib/python3.6/site-packages/torch/nn/modules/conv.py", line 342, in conv2d_forward
self.padding, self.dilation, self.groups)
RuntimeError: Input type (torch.FloatTensor) and weight type (torch.cuda.FloatTensor) should be the same
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.