Merge 23593a6b853a9fb60a805ddfecba6f1e7837753f into 4e14032c02d580e8f54f1e336199e2dee4340ef9

This commit is contained in:
Vijay 2024-12-13 14:39:47 +02:00 committed by GitHub
commit b36d232ccd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 3 deletions

View File

@ -237,6 +237,8 @@ if __name__ == "__main__":
folder_paths.add_model_folder_path("vae", os.path.join(folder_paths.get_output_directory(), "vae"))
folder_paths.add_model_folder_path("diffusion_models", os.path.join(folder_paths.get_output_directory(), "diffusion_models"))
folder_paths.add_model_folder_path("loras", os.path.join(folder_paths.get_output_directory(), "loras"))
folder_paths.add_model_folder_path("latents", os.path.join(folder_paths.get_output_directory(), "latents"))
if args.input_directory:
input_dir = os.path.abspath(args.input_directory)

View File

@ -482,9 +482,8 @@ class SaveLatent:
class LoadLatent:
@classmethod
def INPUT_TYPES(s):
input_dir = folder_paths.get_input_directory()
files = [f for f in os.listdir(input_dir) if os.path.isfile(os.path.join(input_dir, f)) and f.endswith(".latent")]
return {"required": {"latent": [sorted(files), ]}, }
return {"required": {"latent": (folder_paths.get_filename_list("latents"), {"tooltip": "The name of the latent from output/latents to load."})}}
CATEGORY = "_for_testing"