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 3165d1c commit 4416873Copy full SHA for 4416873
stumpy/core.py
@@ -429,11 +429,11 @@ def check_dtype(a, dtype=np.float64): # pragma: no cover
429
TypeError
430
If the array type does not match `dtype`
431
"""
432
- if dtype == int:
+ if dtype is int:
433
dtype = np.int64
434
- if dtype == float:
+ if dtype is float:
435
dtype = np.float64
436
- if dtype == bool:
+ if dtype is bool:
437
dtype = np.bool_
438
if not np.issubdtype(a.dtype, dtype):
439
msg = f"{dtype} dtype expected but found {a.dtype} in input array\n"
0 commit comments