Michelangiolo commited on
Commit
8b29749
1 Parent(s): d670aa7
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -42,7 +42,7 @@ def search(df, query):
42
  # product = df.iloc[0]['text_vector_'] #use one of the products as sample
43
 
44
  #prepare model
45
- nbrs = NearestNeighbors(n_neighbors=50, algorithm='ball_tree').fit(df['text_vector_'].values.tolist())
46
 
47
  distances, indices = nbrs.kneighbors([product]) #input the vector of the reference object
48
 
 
42
  # product = df.iloc[0]['text_vector_'] #use one of the products as sample
43
 
44
  #prepare model
45
+ nbrs = NearestNeighbors(n_neighbors=20, algorithm='ball_tree').fit(df['text_vector_'].values.tolist())
46
 
47
  distances, indices = nbrs.kneighbors([product]) #input the vector of the reference object
48