Skip to content

Commit f981dfe

Browse files
committed
Fix issues found by ruff
1 parent b7ead97 commit f981dfe

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ethicml/data/csvs/make_adult_from_raw.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def run_generate_adult() -> None:
3636
all_data = pd.concat([train, test], axis=0)
3737

3838
for col in all_data.columns:
39-
if all_data[col].dtype == np.object: # type: ignore[attr-defined]
39+
if all_data[col].dtype == object: # type: ignore[attr-defined]
4040
all_data[col] = all_data[col].str.strip()
4141

4242
# Replace full stop in the label of the test set

ethicml/data/csvs/make_crime_from_raw.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ def run_generate_crime() -> None:
160160
data.columns = pd.Index(columns)
161161

162162
for col in data.columns:
163-
if data[col].dtype == np.object: # type: ignore[attr-defined]
163+
if data[col].dtype == object: # type: ignore[attr-defined]
164164
data[col] = data[col].str.strip()
165165

166166
# Drop NaNs

0 commit comments

Comments
 (0)