mirror of
https://git.datalinker.icu/comfyanonymous/ComfyUI
synced 2026-09-28 00:27:11 +08:00
pretty that up a tad
This commit is contained in:
parent
6fca6e1746
commit
67a69da55f
@ -217,14 +217,17 @@ def get_folder_paths(folder_name: str) -> list[str]:
|
|||||||
|
|
||||||
def prebuild_lists():
|
def prebuild_lists():
|
||||||
start_time = time.perf_counter()
|
start_time = time.perf_counter()
|
||||||
|
|
||||||
with ThreadPoolExecutor(32) as executor:
|
with ThreadPoolExecutor(32) as executor:
|
||||||
calls = []
|
calls = []
|
||||||
for folder_name in folder_names_and_paths:
|
for folder_name in folder_names_and_paths:
|
||||||
calls.append(executor.submit(lambda: get_filename_list(folder_name)))
|
calls.append(executor.submit(lambda: get_filename_list(folder_name)))
|
||||||
|
|
||||||
for call in calls:
|
for call in calls:
|
||||||
call.result()
|
call.result()
|
||||||
|
|
||||||
end_time = time.perf_counter()
|
end_time = time.perf_counter()
|
||||||
logging.info("Scanned model lists in {:.2f} seconds".format(end_time - start_time))
|
logging.info(f"Scanned model lists in {end_time - start_time:.2f} seconds")
|
||||||
|
|
||||||
|
|
||||||
def recursive_search(directory: str, excluded_dir_names: list[str] | None=None) -> tuple[list[str], dict[str, float]]:
|
def recursive_search(directory: str, excluded_dir_names: list[str] | None=None) -> tuple[list[str], dict[str, float]]:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user