Skip to content

Commit

Permalink
Merge pull request #1651 from ywkim92/patch-1
Browse files Browse the repository at this point in the history
fix: Change formats of user_ids and item_ids arg.
  • Loading branch information
miguelgfierro authored Feb 19, 2022
2 parents 4639087 + 6149723 commit 6c53f92
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions recommenders/models/lightfm/lightfm_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,8 @@ def prepare_all_predictions(

all_predictions["prediction"] = all_predictions.apply(
lambda x: model.predict(
user_ids=int(x["uid"]),
item_ids=[x["iid"]],
user_ids=np.array([x["uid"]], dtype=np.int32),
item_ids=np.array([x["iid"]], dtype=np.int32),
user_features=user_features,
item_features=item_features,
num_threads=num_threads,
Expand Down

0 comments on commit 6c53f92

Please sign in to comment.