RUCAIBox / RecBole

A unified, comprehensive and efficient recommendation library
https://recbole.io/
MIT License
3.43k stars 614 forks source link

[🐛BUG] 你好,我用movielens_1m数据集 运行模型,出现下面的错误,请问该怎么解决呢? #1541

Closed MambaDong closed 1 year ago

MambaDong commented 1 year ago

你好,我用movielens_1m数据集 运行模型,出现下面的错误,请问该怎么解决呢?

image

谢谢!

AoiDragon commented 1 year ago

@MambaDong 您好,可以提供一下使用的模型以及配置文件吗?

MambaDong commented 1 year ago

be9a36d6dfbde4dc54d72d0cb3bee15 您好,这个是GC-SAN模型 其他类似的Bert模型也不能运行, image

MambaDong commented 1 year ago

你好打扰,麻烦问下这个问题解决了吗

AoiDragon commented 1 year ago

在RecBole1.1中我们将neg_sampling替换为train_neg_sample_args,您可以尝试更新框架后使用新的参数。在其他设置相同的情况下,我这边并没有发现错误。

Sherry-XLL commented 1 year ago

您好 @MambaDong,

可能是您的配置文件导致了 timestamp 属性没有被正确加载。MovieLens-1M 在 GCSAN 等序列模型的参考配置如下:

# dataset config
field_separator: "\t"
seq_separator: " "
USER_ID_FIELD: user_id
ITEM_ID_FIELD: item_id
RATING_FIELD: rating
TIME_FIELD: timestamp
NEG_PREFIX: neg_
ITEM_LIST_LENGTH_FIELD: item_length
LIST_SUFFIX: _list
MAX_ITEM_LIST_LENGTH: 50
POSITION_FIELD: position_id
load_col:
    inter: [user_id, item_id, rating, timestamp]

# data filtering for interactions
val_interval:
    rating: "[3,inf)"    
unused_col: 
    inter: [rating]

user_inter_num_interval: "[10,inf)"
item_inter_num_interval: "[10,inf)"

# training and evaluation
epochs: 500
train_batch_size: 4096
eval_batch_size: 40960000
valid_metric: NDCG@10
eval_args:
    split: {'LS': 'valid_and_test'}
    mode: full
    order: TO

# disable negative sampling
train_neg_sample_args: ~

欢迎您更新伯乐到最新版本,按照如上 .yml 新建配置文件并重新运行代码。

感谢您对伯乐的关注,若有新的问题欢迎新开一个 issue 提问。

AbdElrahmanMostafaRifaat1432 commented 1 year ago

can anyone here help me with my problem in #1670 any help will be appreciated from you