stable-baselines3 icon indicating copy to clipboard operation
stable-baselines3 copied to clipboard

Allow different data types in her replay buffer

Open buoyancy99 opened this issue 3 years ago • 2 comments

It seems that HER replay buffer is always created with np.float32, while other buffers are created with same dtype as observation space. Shall we change it here? People use different dtypes to save memory. I can create a PR if this is not intentional

https://github.com/DLR-RM/stable-baselines3/blob/e9a8979022d7005560d43b7a9c1dc1ba85f7989a/stable_baselines3/her/her_replay_buffer.py#L146

buoyancy99 avatar Jan 06 '22 00:01 buoyancy99

Somewhat related issue #675 and PR #686

Sounds good to me if rest of the code plays well with this change (e.g. see fuzz in #675). I agree with float dtypes it would waste a lot of space :). @araffin Further comments?

Miffyli avatar Jan 06 '22 11:01 Miffyli

Hello, I do agree for observation and goal and we can probably address it in https://github.com/DLR-RM/stable-baselines3/pull/704

araffin avatar Jan 07 '22 09:01 araffin