Michela commited on
Commit
ff0861b
·
1 Parent(s): 4bd560f

debugging path continued

Browse files
Files changed (1) hide show
  1. app.py +6 -11
app.py CHANGED
@@ -7,17 +7,12 @@ import os
7
  # Get script's directory
8
  script_dir = os.path.dirname(os.path.abspath(__file__))
9
 
10
- '''### Debugging ###
11
- # Construct the full path to the CSV file
12
- file_path = os.path.join(script_dir, "data/retrieval_results/sonnini_original_ocr/i_onit-test-index-sonnini-q_Pferd-Pferde.csv")
13
-
14
- # Debugging: Print and check if the file exists
15
- print(f"Resolved file path: {file_path}")
16
- print(f"File exists? {os.path.exists(file_path)}")
17
-
18
- if not os.path.exists(file_path):
19
- raise FileNotFoundError(f"File not found at: {file_path}")
20
- ####'''
21
 
22
  # Import results
23
  results_clean = pd.read_csv("../data/retrieval_results/sonnini_cleaned/i_onit-sonnini-DHd2025-clean-q_Pferd, Pferde.csv").head(100)
 
7
  # Get script's directory
8
  script_dir = os.path.dirname(os.path.abspath(__file__))
9
 
10
+ ### Debugging ###
11
+ # Print the contents of the data directory
12
+ data_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), "data/retrieval_results/sonnini_original_ocr")
13
+ print(f"Checking folder: {data_path}")
14
+ print("Files in directory:", os.listdir(data_path) if os.path.exists(data_path) else "Directory not found!")
15
+ ####
 
 
 
 
 
16
 
17
  # Import results
18
  results_clean = pd.read_csv("../data/retrieval_results/sonnini_cleaned/i_onit-sonnini-DHd2025-clean-q_Pferd, Pferde.csv").head(100)