update
Browse files- constants.py +0 -5
- demo/client.py +6 -2
constants.py
CHANGED
@@ -1,8 +1,6 @@
|
|
1 |
from pathlib import Path
|
2 |
import os
|
3 |
|
4 |
-
print("here0")
|
5 |
-
|
6 |
UNIDISC_DIR = Path(os.getenv("UNIDISC_DIR", Path(__file__).parent))
|
7 |
LIB_DIR = UNIDISC_DIR / "third_party"
|
8 |
CELEBV_DATA_DIR = Path(os.getenv("CELEBV_DATA_DIR", "/home/mprabhud/aswerdlo/repos/lib/CelebV-Text/downloaded_celebvtext"))
|
@@ -12,7 +10,6 @@ HF_TOKEN = os.getenv("HF_TOKEN", os.getenv("HF_HUB_DATASETS_TOKEN"))
|
|
12 |
HF_DATASETS_CACHE = os.getenv("HF_DATASETS_CACHE", None)
|
13 |
HF_CACHE_DIR = os.getenv("HF_HOME", None)
|
14 |
|
15 |
-
print("here1")
|
16 |
if HF_CACHE_DIR is not None:
|
17 |
HF_CACHE_DIR = Path(HF_CACHE_DIR)
|
18 |
elif HF_DATASETS_CACHE is not None:
|
@@ -24,5 +21,3 @@ try:
|
|
24 |
CELEBV_DATA_DIR = SCRATCH_CELEBV_DATA_DIR
|
25 |
except:
|
26 |
print(f"Error setting CELEBV_DATA_DIR")
|
27 |
-
|
28 |
-
print("here2")
|
|
|
1 |
from pathlib import Path
|
2 |
import os
|
3 |
|
|
|
|
|
4 |
UNIDISC_DIR = Path(os.getenv("UNIDISC_DIR", Path(__file__).parent))
|
5 |
LIB_DIR = UNIDISC_DIR / "third_party"
|
6 |
CELEBV_DATA_DIR = Path(os.getenv("CELEBV_DATA_DIR", "/home/mprabhud/aswerdlo/repos/lib/CelebV-Text/downloaded_celebvtext"))
|
|
|
10 |
HF_DATASETS_CACHE = os.getenv("HF_DATASETS_CACHE", None)
|
11 |
HF_CACHE_DIR = os.getenv("HF_HOME", None)
|
12 |
|
|
|
13 |
if HF_CACHE_DIR is not None:
|
14 |
HF_CACHE_DIR = Path(HF_CACHE_DIR)
|
15 |
elif HF_DATASETS_CACHE is not None:
|
|
|
21 |
CELEBV_DATA_DIR = SCRATCH_CELEBV_DATA_DIR
|
22 |
except:
|
23 |
print(f"Error setting CELEBV_DATA_DIR")
|
|
|
|
demo/client.py
CHANGED
@@ -9,10 +9,14 @@ import numpy as np
|
|
9 |
import io
|
10 |
import json
|
11 |
|
|
|
|
|
12 |
SHOW_DEV_BUTTONS = True
|
13 |
-
DEMO_DIR = Path(
|
14 |
ADD_DEV_FORM = True
|
15 |
|
|
|
|
|
16 |
DEMOS = [
|
17 |
{
|
18 |
"name": "Dog",
|
@@ -656,5 +660,5 @@ def post(
|
|
656 |
|
657 |
return output_content
|
658 |
|
659 |
-
|
660 |
serve(port=5003)
|
|
|
9 |
import io
|
10 |
import json
|
11 |
|
12 |
+
print(f"Finished import 0")
|
13 |
+
|
14 |
SHOW_DEV_BUTTONS = True
|
15 |
+
DEMO_DIR = Path(__file__).parent
|
16 |
ADD_DEV_FORM = True
|
17 |
|
18 |
+
print(f"Finished import 1. Demo dir: {DEMO_DIR}")
|
19 |
+
|
20 |
DEMOS = [
|
21 |
{
|
22 |
"name": "Dog",
|
|
|
660 |
|
661 |
return output_content
|
662 |
|
663 |
+
print(f"Before serve...")
|
664 |
serve(port=5003)
|