Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
@@ -11,10 +11,10 @@ def remove_cache(folder_path):
|
|
11 |
if os.path.isfile(file_path): # Kiểm tra nếu là file
|
12 |
os.remove(file_path)
|
13 |
def main(file_path = "./data/input/sample.pdf", analysis_level='basic', writting_style='academic', word_lower_limit=100, word_upper_limit = 150, gender = "female", speed = "fast", number_of_images = 3, detail_level="short", perspective="neutral", emotion="sad", time_setting="classic", art_style="realistic", style="anime", color_palette="monochrome"):
|
14 |
-
remove_cache("./
|
15 |
-
remove_cache("./
|
16 |
-
remove_cache("./
|
17 |
-
remove_cache("./
|
18 |
text_processing(file_path = file_path, analysis_level=analysis_level, writting_style=writting_style, word_lower_limit = word_lower_limit, word_upper_limit=word_upper_limit )
|
19 |
text_to_speech(gender = gender, speed = speed)
|
20 |
image_gen(number_of_images = number_of_images, detail_level=detail_level, perspective=perspective, emotion=emotion, time_setting=time_setting, art_style=art_style, style=style, color_palette=color_palette)
|
|
|
11 |
if os.path.isfile(file_path): # Kiểm tra nếu là file
|
12 |
os.remove(file_path)
|
13 |
def main(file_path = "./data/input/sample.pdf", analysis_level='basic', writting_style='academic', word_lower_limit=100, word_upper_limit = 150, gender = "female", speed = "fast", number_of_images = 3, detail_level="short", perspective="neutral", emotion="sad", time_setting="classic", art_style="realistic", style="anime", color_palette="monochrome"):
|
14 |
+
remove_cache("./audio")
|
15 |
+
remove_cache("./image")
|
16 |
+
remove_cache("./text")
|
17 |
+
remove_cache("./output")
|
18 |
text_processing(file_path = file_path, analysis_level=analysis_level, writting_style=writting_style, word_lower_limit = word_lower_limit, word_upper_limit=word_upper_limit )
|
19 |
text_to_speech(gender = gender, speed = speed)
|
20 |
image_gen(number_of_images = number_of_images, detail_level=detail_level, perspective=perspective, emotion=emotion, time_setting=time_setting, art_style=art_style, style=style, color_palette=color_palette)
|