stefanoviel
commited on
Commit
·
c25929c
1
Parent(s):
2c1d8e4
fixing paths
Browse files- src/streamlit_app.py +7 -5
src/streamlit_app.py
CHANGED
@@ -5,12 +5,14 @@ from sentence_transformers import SentenceTransformer, util
|
|
5 |
import torch
|
6 |
from spellchecker import SpellChecker
|
7 |
from io import StringIO
|
|
|
8 |
|
9 |
-
|
10 |
-
|
11 |
-
#
|
12 |
-
|
13 |
-
|
|
|
14 |
|
15 |
# --- Data Loading and Preparation ---
|
16 |
CSV_FILE = 'papers_with_abstracts_parallel.csv'
|
|
|
5 |
import torch
|
6 |
from spellchecker import SpellChecker
|
7 |
from io import StringIO
|
8 |
+
from pathlib import Path
|
9 |
|
10 |
+
script_dir = Path(__file__).parent
|
11 |
+
|
12 |
+
# Define paths relative to the script's directory
|
13 |
+
DATA_FILE = script_dir / 'papers_data.pkl'
|
14 |
+
EMBEDDINGS_FILE = script_dir / 'paper_embeddings.pt'
|
15 |
+
CSV_FILE = script_dir / 'papers_with_abstracts_parallel.csv'
|
16 |
|
17 |
# --- Data Loading and Preparation ---
|
18 |
CSV_FILE = 'papers_with_abstracts_parallel.csv'
|