2018-03-03 20:42:34 +08:00
|
|
|
|
|
|
|
|
2018-03-09 15:07:14 +08:00
|
|
|
class DataBufferBase(object):
|
2018-03-03 20:42:34 +08:00
|
|
|
"""
|
2018-03-09 15:07:14 +08:00
|
|
|
base class for data buffer, including replay buffer as in DQN and batched dataset as in on-policy algos
|
2018-03-03 20:42:34 +08:00
|
|
|
"""
|
|
|
|
def add(self, frame):
|
|
|
|
raise NotImplementedError()
|
|
|
|
|
2018-03-09 15:07:14 +08:00
|
|
|
def clear(self):
|
2018-03-03 20:42:34 +08:00
|
|
|
raise NotImplementedError()
|
|
|
|
|
|
|
|
def sample(self, batch_size):
|
|
|
|
raise NotImplementedError()
|