Skip to content

Commit 6c53f92

Browse files
Merge pull request #1651 from ywkim92/patch-1
fix: Change formats of user_ids and item_ids arg.
2 parents 4639087 + 6149723 commit 6c53f92

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

recommenders/models/lightfm/lightfm_utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@ def prepare_all_predictions(
253253

254254
all_predictions["prediction"] = all_predictions.apply(
255255
lambda x: model.predict(
256-
user_ids=int(x["uid"]),
257-
item_ids=[x["iid"]],
256+
user_ids=np.array([x["uid"]], dtype=np.int32),
257+
item_ids=np.array([x["iid"]], dtype=np.int32),
258258
user_features=user_features,
259259
item_features=item_features,
260260
num_threads=num_threads,

0 commit comments

Comments
 (0)