danschnurp commited on
Commit
20f654b
·
verified ·
1 Parent(s): 6dad69b

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -56,8 +56,8 @@ def create_embedding(dataset):
56
 
57
 
58
  def build_faiss_index(dataset: pd.DataFrame) -> Tuple[faiss.IndexFlatIP, np.ndarray]:
59
- if os.path.exists("data/books.index"):
60
- return read_index("data/books.index")
61
 
62
  dataset["embedding"] = create_embedding(dataset["Book-Title"])
63
  print("creating index")
 
56
 
57
 
58
  def build_faiss_index(dataset: pd.DataFrame) -> Tuple[faiss.IndexFlatIP, np.ndarray]:
59
+ if os.path.exists("books.index"):
60
+ return read_index("books.index")
61
 
62
  dataset["embedding"] = create_embedding(dataset["Book-Title"])
63
  print("creating index")