【FIRE】Fast Incremental Recommendation with Graph Signal Processing

FIRE

code

dataloader

对数据集进行预处理,并根据超参数进行增量学习。

get_user_item_sim_mat
get_sim_mat
get_init_mats
get_train_test_data
get_date_from_timestamp

metric

计算衡量指标 F1、MRR、NDCG三项指标。
calculate_precision_recall_f1()
calculate_mrr()
calculate_ndcg()

analyse

MovieLens 1M

将ratings.csv数据集划分为训练集和测试集。

比如:ratings.csv中共有892982条数据,其中777387条用作训练,115595用作测试。

测试集包含两部分:

  • historical records: 488938 条记录
  • current records: 288449 条记录
dataframe u i r t m
0 0 0 4 957110420 0
1 0 1 4 957110420 0
2 0 2 4 957110420 0
3 0 3 4 957110420 0
4 0 4 5 957110444 0
777382 5289 62 5 975599952 6
777383 5289 488 3 975599968 6
777384 5289 1382 5 975599968 6
777385 5289 1195 4 975599985 6
777386 5289 862 5 975599985 6

测试集如下:

dataframe u i r t m
0 5289 1025 2 975600009 7
1 5289 1474 4 975600009 7
2 5289 123 5 975600009 7
3 4371 2287 5 975600014 7
4 5289 1094 4 975600029 7
115590 1855 334 4 978276135 7
115591 1855 298 4 978276165 7
115592 1855 313 4 978276197 7
115593 1855 799 3 978276226 7
115594 1855 1710 1 978276264 7

衡量指标:F1、MRR、NDCG
与最先进的增量推荐算法(BPR、IFM、SML等)相比,FIRE 可以大幅提高准确性。

Test metrics:

扫描二维码关注公众号,回复: 14562103 查看本文章
  • Top5: F1:0.0699 MRR:0.4218 NDCG:0.4713
  • Top10: F1:0.1120 MRR:0.4105 NDCG:0.4805

而且,将模型更新效率提高至少3倍。

Time info:

  • Training phase consumes: 1.93 s
  • Test phase consumes: 21.50 s
  • Total time consumes: 23.43 s

Douban Movie

测试集包含两部分:

  • historical records: 681171 条记录
  • current records: 103876 条记录
dataframe u i r t m
0 916 2444 3 1199118064 0
1 962 2194 3 1199119069 0
2 842 1137 5 1199119473 0
3 409 2920 4 1199120568 0
4 460 3100 4 1199123126 0
785042 7283 1748 5 1514735496 9
785043 8382 8705 3 1514735573 9
785044 8275 4330 3 1514735639 9
785045 2296 9264 2 1514735806 9
785046 2296 8920 3 1514735933 9

测试集如下:

dataframe u i r t m
0 5442 8752 2 1514736417 10
1 8291 5346 5 1514736435 10
2 1884 9161 5 1514736466 10
3 4199 2765 5 1514736479 10
4 9365 9126 2 1514736590 10
216866 2940 7940 4 1567837805 11
216867 8108 9997 5 1567837919 11
216868 6157 654 4 1567838962 11
216869 1294 1363 4 1567839436 11
216870 9861 4294 4 1567839568 11

下面是Douban数据集的性能指标。
Test metrics:

  • Top5: F1:0.0094 MRR:0.0272 NDCG:0.0348
  • Top10: F1:0.0127 MRR:0.0305 NDCG:0.0456

Time info:

  • Training phase consumes: 5.86 s
  • Test phase consumes: 249.54 s
  • Total time consumes: 255.40 s

猜你喜欢

转载自blog.csdn.net/qq_44824148/article/details/128643165
今日推荐