From 52da180f35b8ee4f055cea78404f0de25d883f1b Mon Sep 17 00:00:00 2001 From: Soonmok Date: Tue, 4 Oct 2022 22:01:50 +0900 Subject: [PATCH] Remove unnecessary argument --- implicit/_nearest_neighbours.pyx | 2 +- implicit/nearest_neighbours.py | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/implicit/_nearest_neighbours.pyx b/implicit/_nearest_neighbours.pyx index 91d3860..2d4a00d 100644 --- a/implicit/_nearest_neighbours.pyx +++ b/implicit/_nearest_neighbours.pyx @@ -49,7 +49,7 @@ cdef class NearestNeighboursScorer(object): self.lock = threading.RLock() @cython.boundscheck(False) - def recommend(self, int u, int[:] user_indptr, int[:] user_indices, floating[:] user_data, + def recommend(self, int[:] user_indptr, int[:] user_indices, floating[:] user_data, int K=10, bool remove_own_likes=True): cdef int index1, index2, i, count cdef double weight diff --git a/implicit/nearest_neighbours.py b/implicit/nearest_neighbours.py index 7aad875..123ddd4 100644 --- a/implicit/nearest_neighbours.py +++ b/implicit/nearest_neighbours.py @@ -81,7 +81,6 @@ def recommend( raise IndexError("Some of selected itemids are not in the model") ids, scores = self.scorer.recommend( - userid, user_items.indptr, user_items.indices, user_items.data,