as_numpy_dtype is a property (so this effectively returns 0)
PiperOrigin-RevId: 285859645 Change-Id: Ifd3656ef665ae19591414ab6051dd19a68b99bf4
This commit is contained in:
parent
2dc7a885a0
commit
486ac20961
@ -255,10 +255,10 @@ class BoundedTensorSpec(TensorSpec):
|
||||
raise ValueError("maximum is not compatible with shape. "
|
||||
"Message: {!r}.".format(exception))
|
||||
|
||||
self._minimum = np.array(minimum, dtype=self.dtype.as_numpy_dtype())
|
||||
self._minimum = np.array(minimum, dtype=self.dtype.as_numpy_dtype)
|
||||
self._minimum.setflags(write=False)
|
||||
|
||||
self._maximum = np.array(maximum, dtype=self.dtype.as_numpy_dtype())
|
||||
self._maximum = np.array(maximum, dtype=self.dtype.as_numpy_dtype)
|
||||
self._maximum.setflags(write=False)
|
||||
|
||||
@classmethod
|
||||
|
Loading…
Reference in New Issue
Block a user