Spaces:
Running
Running
new changes
Browse files
comic_panel_extractor/server.py
CHANGED
|
@@ -17,10 +17,12 @@ from pathlib import Path
|
|
| 17 |
import shutil
|
| 18 |
import time
|
| 19 |
|
|
|
|
|
|
|
| 20 |
base_output_folder = "api_outputs"
|
| 21 |
static_folder = "./static"
|
| 22 |
-
output_folder = os.path.
|
| 23 |
-
static_folder = os.path.
|
| 24 |
|
| 25 |
# Create directories for uploads and outputs
|
| 26 |
os.makedirs(output_folder, exist_ok=True)
|
|
|
|
| 17 |
import shutil
|
| 18 |
import time
|
| 19 |
|
| 20 |
+
current_path = os.path.abspath(os.path.join(os.path.dirname(__file__)))
|
| 21 |
+
|
| 22 |
base_output_folder = "api_outputs"
|
| 23 |
static_folder = "./static"
|
| 24 |
+
output_folder = os.path.join(current_path, base_output_folder)
|
| 25 |
+
static_folder = os.path.join(current_path, static_folder)
|
| 26 |
|
| 27 |
# Create directories for uploads and outputs
|
| 28 |
os.makedirs(output_folder, exist_ok=True)
|