mirror of
https://github.com/wassname/ray.git
synced 2026-08-03 13:10:57 +08:00
SAC Performance Fixes (#6295)
* SAC Performance Fixes * Small Changes * Update sac_model.py * fix normalize wrapper * Update test_eager_support.py Co-authored-by: Eric Liang <ekhliang@gmail.com>
This commit is contained in:
committed by
Eric Liang
co-authored by
Eric Liang
parent
eca4cc7c00
commit
548df014ec
@@ -70,10 +70,7 @@ class ReplayBuffer(object):
|
||||
|
||||
@DeveloperAPI
|
||||
def sample_idxes(self, batch_size):
|
||||
return [
|
||||
random.randint(0,
|
||||
len(self._storage) - 1) for _ in range(batch_size)
|
||||
]
|
||||
return np.random.randint(0, len(self._storage), batch_size)
|
||||
|
||||
@DeveloperAPI
|
||||
def sample_with_idxes(self, idxes):
|
||||
|
||||
Reference in New Issue
Block a user