We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fb86c46 commit 1a92165Copy full SHA for 1a92165
pytensor/printing.py
@@ -1847,7 +1847,7 @@ def hex_digest(x):
1847
Returns a short, mostly hexadecimal hash of a numpy ndarray
1848
"""
1849
assert isinstance(x, np.ndarray)
1850
- rval = hashlib.sha256(x.tostring()).hexdigest()
+ rval = hashlib.sha256(x.tobytes()).hexdigest()
1851
# hex digest must be annotated with strides to avoid collisions
1852
# because the buffer interface only exposes the raw data, not
1853
# any info about the semantics of how that data should be arranged
0 commit comments