Update app.py
Browse files
app.py
CHANGED
@@ -20,11 +20,11 @@ def get_examples(examples_dir: str = "assets/examples/ghibli-fine-tuned-sd-2.1")
|
|
20 |
# Check if the directory exists
|
21 |
if not os.path.exists(examples_dir) or not os.path.isdir(examples_dir):
|
22 |
raise ValueError(f"Directory {examples_dir} does not exist or is not a directory")
|
23 |
-
|
24 |
# Get list of subfolder paths (e.g., 1, 2, etc.)
|
25 |
all_examples_dir = [os.path.join(examples_dir, d) for d in os.listdir(examples_dir)
|
26 |
if os.path.isdir(os.path.join(examples_dir, d))]
|
27 |
-
|
28 |
ans = []
|
29 |
for example_dir in all_examples_dir:
|
30 |
config_path = os.path.join(example_dir, "config.json")
|
|
|
20 |
# Check if the directory exists
|
21 |
if not os.path.exists(examples_dir) or not os.path.isdir(examples_dir):
|
22 |
raise ValueError(f"Directory {examples_dir} does not exist or is not a directory")
|
23 |
+
|
24 |
# Get list of subfolder paths (e.g., 1, 2, etc.)
|
25 |
all_examples_dir = [os.path.join(examples_dir, d) for d in os.listdir(examples_dir)
|
26 |
if os.path.isdir(os.path.join(examples_dir, d))]
|
27 |
+
|
28 |
ans = []
|
29 |
for example_dir in all_examples_dir:
|
30 |
config_path = os.path.join(example_dir, "config.json")
|