-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Labels
array-apiWork is related to the Array APIWork is related to the Array APIbugSomething isn't workingSomething isn't working
Description
Describe the Bug
This won't be an issue most of the time, but I think strictly speaking we should replace it with
@property
def __key(self) -> AnyArray:
"""Return next key for sampling while updating internal state."""
with self.lock:
self.key, key = jax.random.split(self.key)
key.block_until_ready()
return keywithout this in calls like loc + scale * jax.random.normal(self.__key, _size(size), dtype) the key state might advance before the random number is generated.
To Reproduce
import glass
...Expected Behaviour
No response
Actual Behaviour
No response
Version In Use
2025.4.dev117+gc61a78dad.d20260127
Additional Context
- Python version:
- Operating system:Metadata
Metadata
Assignees
Labels
array-apiWork is related to the Array APIWork is related to the Array APIbugSomething isn't workingSomething isn't working