question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Working example code for R2D1

See original GitHub issue

It seems like the code in experiments/ is outdated - I’ve managed to update the import errors and get most of the code running, however I get the following issue when running the atari_r2d1_gpu.py script:

Traceback (most recent call last):
  File "rlpyt/experiments/scripts/atari/dqn/train/atari_r2d1_gpu.py", line 50, in <module>
    build_and_train(*sys.argv[1:])
  File "rlpyt/experiments/scripts/atari/dqn/train/atari_r2d1_gpu.py", line 46, in build_and_train
    runner.train()
  File "/home/david/Repos/rlpyt/rlpyt/runners/minibatch_rl.py", line 240, in train
    opt_info = self.algo.optimize_agent(itr, samples)
  File "/home/david/Repos/rlpyt/rlpyt/algos/dqn/r2d1.py", line 133, in optimize_agent
    self.replay_buffer.append_samples(samples_to_buffer)
  File "/home/david/Repos/rlpyt/rlpyt/replays/sequence/prioritized.py", line 52, in append_samples
    T, idxs = super().append_samples(samples)
  File "/home/david/Repos/rlpyt/rlpyt/replays/frame.py", line 46, in append_samples
    buffer_samples = BufferSamples(*(v for k, v in samples.items()
TypeError: __new__() missing 2 required positional arguments: 'done' and 'prev_rnn_state'

Any tips on making the required modifications? If not, is there any place in the codebase which has working R2D1 example code?

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
tesslerccommented, Apr 16, 2020

@crizCraig , were you able to fix this? Tried a quick run here and it also hanged. Simple non async stuff (DQN) did work well. —edit— Seems I had some leftover python processes in the background after killing the program several times – killed them all, ran again and waited… it works 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

100DaysOfCode R2D1
What I Learned About: Finished the Pac-Man game from Scrimba, completing module 6Started "Working with API's", module 7, with "Basics of Web ...
Read more >
rlpyt: A Research Code Base for Deep Reinforcement ...
The code examples still introduce ways to run experiments, ... This blog post briefly introduces its features and relation to prior work.
Read more >
Welcome to rlpyt's documentation! — rlpyt documentation
A conceptual overview is provided in the white paper, and the code (with examples) in the github repository. This documentation aims to explain...
Read more >
Locally recoverable codes from algebraic curves and surfaces
paper is different from the present work and relies on considering ... In Section 3 we construct a number of examples of codes...
Read more >
Allen-Bradley 800H-R2D1 - Revere Electric Supply
We use essential cookies to make our site work. With your consent, we may also use non-essential cookies to improve user experience and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found