baselines icon indicating copy to clipboard operation
baselines copied to clipboard

Bug in baselines/deepq/replay_buffer.py

Open RukawaKaede opened this issue 5 years ago • 1 comments

Hi: I found a bug in this line in replay_buffer.py. Since this line in common/segment_tree.py has already subtracted 1 of 'end', the recursion will run forever when end=0 (after substract 1, end=-1) passed to the reduce method in SegmentTree.

RukawaKaede avatar Jan 05 '20 13:01 RukawaKaede

Hi: I found a bug in this line in replay_buffer.py. Since this line in common/segment_tree.py has already subtracted 1 of 'end', the recursion will run forever when end=0 (after substract 1, end=-1) passed to the reduce method in SegmentTree.

hi, can you help me explain why here need to subtracted 1. (len(self._storage - 1)) is already subtracted 1. For example, if i want to know the sum of 0-7. By subtracted twice ,it will be 0-6. why? Thank you!

EthanCodesss avatar Mar 15 '21 05:03 EthanCodesss