Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/306.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 利用惊喜构建推荐系统_Python_Recommender Systems - Fatal编程技术网

Python 利用惊喜构建推荐系统

Python 利用惊喜构建推荐系统,python,recommender-systems,Python,Recommender Systems,所以我使用了这个名为惊喜的python库: 我遇到的问题是,当我遇到这个错误时,我无法让我的算法正确预测。 但是,正如您在my dataframe中看到的,该项确实存在: 我按照文档正确加载数据,使用: # The columns must correspond to user id, item id and ratings (in that order). train_data = Dataset.load_from_df(games_data[['userid', 'name',

所以我使用了这个名为惊喜的python库:

我遇到的问题是,当我遇到这个错误时,我无法让我的算法正确预测。

但是,正如您在my dataframe中看到的,该项确实存在:

我按照文档正确加载数据,使用:

 # The columns must correspond to user id, item id and ratings (in that order). 
 train_data = Dataset.load_from_df(games_data[['userid', 'name', 'metascore']], reader) 
文档建议我看一下这个,但我被它弄糊涂了


我做错了什么?谢谢。

这方面运气好吗?我也是这个软件包的新手,但我想知道是否因为数据类型问题而找不到用户。可能需要强制用户或项目使用字符串或数字进行匹配

你能分享游戏吗?\u data.info()


祝你好运

这方面运气好吗?我也是这个软件包的新手,但我想知道是否因为数据类型问题而找不到用户。可能需要强制用户或项目使用字符串或数字进行匹配

你能分享游戏吗?\u data.info()


祝你好运

您的原始id是用字符串还是字母数字括起来的?我的原始id是字符串。您的原始id是用字符串还是字母数字括起来的?我的原始id是字符串。您好,问题出在我的数据集上。为了让算法认为“项存在”,每个用户需要有多个评级。嗨,问题是我的数据集。为了让算法认为“项目存在”,每个用户需要有多个评级。