mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-19 01:51:30 +00:00
25 lines
426 B
Python
25 lines
426 B
Python
import numpy as npy
|
|
import numpy as np
|
|
import numpy
|
|
|
|
# Error
|
|
npy.bool
|
|
npy.int
|
|
|
|
if dtype == np.object:
|
|
...
|
|
|
|
result = result.select_dtypes([np.byte, np.ubyte, np.short, np.ushort, np.int, np.long])
|
|
|
|
pdf = pd.DataFrame(
|
|
data=[[1, 2, 3]],
|
|
columns=["a", "b", "c"],
|
|
dtype=numpy.object,
|
|
)
|
|
|
|
_ = arr.astype(np.int)
|
|
|
|
# Regression test for: https://github.com/astral-sh/ruff/issues/6952
|
|
from numpy import float
|
|
|
|
float(1)
|