We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ValueError Traceback (most recent call last) Input In [9], in 28 # Create recommendations for customer with id 2 29 customer_id = 2 ---> 30 recommendations = recommend(customer_id, sparse_customer_item, customer_vecs, item_vecs) 32 print(recommendations)
Input In [9], in recommend(customer_id, sparse_customer_item, customer_vecs, item_vecs, num_items) 9 min_max = MinMaxScaler() 10 rec_vector_scaled = min_max.fit_transform(rec_vector.reshape(-1,1))[:,0] ---> 11 recommend_vector = customer_interactions * rec_vector_scaled 13 item_idx = np.argsort(recommend_vector)[::-1][:num_items] 15 descriptions = []
ValueError: operands could not be broadcast together with shapes (3664,) (4338,)
The text was updated successfully, but these errors were encountered:
I have similar issue :/ Bump
Sorry, something went wrong.
replace model section in notebook with following: `model = implicit.als.AlternatingLeastSquares(factors=20, regularization=0.1, iterations=50)
alpha = 15 data = (sparse_customer_item * alpha).astype('double')
model.fit(data)`
implicit model expects customer_item data
No branches or pull requests
ValueError Traceback (most recent call last)
Input In [9], in
28 # Create recommendations for customer with id 2
29 customer_id = 2
---> 30 recommendations = recommend(customer_id, sparse_customer_item, customer_vecs, item_vecs)
32 print(recommendations)
Input In [9], in recommend(customer_id, sparse_customer_item, customer_vecs, item_vecs, num_items)
9 min_max = MinMaxScaler()
10 rec_vector_scaled = min_max.fit_transform(rec_vector.reshape(-1,1))[:,0]
---> 11 recommend_vector = customer_interactions * rec_vector_scaled
13 item_idx = np.argsort(recommend_vector)[::-1][:num_items]
15 descriptions = []
ValueError: operands could not be broadcast together with shapes (3664,) (4338,)
The text was updated successfully, but these errors were encountered: