Spaces:
Sleeping
Sleeping
dinhquangson
commited on
Commit
•
3f0b9aa
1
Parent(s):
c92562c
Update app.py
Browse files
app.py
CHANGED
@@ -60,6 +60,7 @@ def generate_embeddings(dataset, text_field, batch_size=32):
|
|
60 |
|
61 |
with tqdm(total=len(dataset), desc=f"Generating embeddings for dataset") as pbar:
|
62 |
for i in range(0, len(dataset), batch_size):
|
|
|
63 |
batch_sentences = dataset[text_field][i:i+batch_size]
|
64 |
batch_embeddings = model.encode(batch_sentences)
|
65 |
embeddings.extend(batch_embeddings)
|
|
|
60 |
|
61 |
with tqdm(total=len(dataset), desc=f"Generating embeddings for dataset") as pbar:
|
62 |
for i in range(0, len(dataset), batch_size):
|
63 |
+
print(dataset)
|
64 |
batch_sentences = dataset[text_field][i:i+batch_size]
|
65 |
batch_embeddings = model.encode(batch_sentences)
|
66 |
embeddings.extend(batch_embeddings)
|