Skip to content

Commit 86f1c40

Browse files
authored
Fix dtype check for numpy boolean array (#158)
1 parent 60739df commit 86f1c40

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎pgvector/bit.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def __init__(
3939
elif is_ndarray(value):
4040
import numpy as np
4141

42-
if value.dtype != np.bool:
42+
if value.dtype != np.bool_:
4343
# skip error for result of np.unpackbits
4444
if value.dtype != np.uint8 or np.any(value > 1):
4545
raise ValueError('expected elements to be boolean')

0 commit comments

Comments
 (0)