fixed read_csv call for deprecation

This commit is contained in:
Lorenzo Volpi 2024-10-30 14:01:41 +01:00
parent a271fe1231
commit 82fe293d3f
1 changed files with 1 additions and 1 deletions

View File

@ -499,7 +499,7 @@ def fetch_UCIBinaryLabelledCollection(dataset_name, data_home=None, standardize=
y = df["NSP"].astype(int).values y = df["NSP"].astype(int).values
elif group == "semeion": elif group == "semeion":
with download_tmp_file("semeion", "semeion.data") as tmp: with download_tmp_file("semeion", "semeion.data") as tmp:
df = pd.read_csv(tmp, header=None, delim_whitespace=True) df = pd.read_csv(tmp, header=None, sep='\s+')
X = df.iloc[:, 0:256].astype(float).values X = df.iloc[:, 0:256].astype(float).values
y = df[263].values # 263 stands for digit 8 (labels are one-hot vectors from col 256-266) y = df[263].values # 263 stands for digit 8 (labels are one-hot vectors from col 256-266)
else: else: