You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
这是我上面替换数据后,出现的错误。
Traceback (most recent call last):
File "/home/yy/FDSA/RecBole-master/run_recbole.py", line 49, in
run(
File "/home/yy/FDSA/RecBole-master/recbole/quick_start/quick_start.py", line 52, in run
res = run_recbole(
File "/home/yy/FDSA/RecBole-master/recbole/quick_start/quick_start.py", line 129, in run_recbole
dataset = create_dataset(config)
File "/home/yy/FDSA/RecBole-master/recbole/data/utils.py", line 72, in create_dataset
dataset = dataset_class(config)
File "/home/yy/FDSA/RecBole-master/recbole/data/dataset/sequential_dataset.py", line 36, in init
super().init(config)
File "/home/yy/FDSA/RecBole-master/recbole/data/dataset/dataset.py", line 108, in init
self._from_scratch()
File "/home/yy/FDSA/RecBole-master/recbole/data/dataset/dataset.py", line 118, in _from_scratch
self._load_data(self.dataset_name, self.dataset_path)
File "/home/yy/FDSA/RecBole-master/recbole/data/dataset/dataset.py", line 272, in _load_data
self.item_feat = self._load_user_or_item_feat(
File "/home/yy/FDSA/RecBole-master/recbole/data/dataset/dataset.py", line 340, in _load_user_or_item_feat
feat = self._load_feat(feat_path, source)
File "/home/yy/FDSA/RecBole-master/recbole/data/dataset/dataset.py", line 462, in _load_feat
field, ftype = field_type.split(":")
ValueError: not enough values to unpack (expected 2, got 1)
在运行过程中发现你们给出的原子文件处理有异常值,例如23年的亚马逊sports数据中在item文件中的price有‘-’,导致无法正常运行
报错如下:
Traceback (most recent call last):
File "/home/yy/.conda/envs/recbole/lib/python3.10/site-packages/pandas/io/parsers/base_parser.py", line 848, in _cast_types
values = astype_array(values, cast_type, copy=True)
File "/home/yy/.conda/envs/recbole/lib/python3.10/site-packages/pandas/core/dtypes/astype.py", line 182, in astype_array
values = _astype_nansafe(values, dtype, copy=copy)
File "/home/yy/.conda/envs/recbole/lib/python3.10/site-packages/pandas/core/dtypes/astype.py", line 133, in _astype_nansafe
return arr.astype(dtype, copy=True)
ValueError: could not convert string to float: '—'
当我用代码希望用None替换这个异常数据的时候,会出现另一个错误。
我的代码如下:
df['price'] = df['price'].replace('-', None)
The text was updated successfully, but these errors were encountered: