From 2af768bfde0029e8e0278776af6105c5d1e01123 Mon Sep 17 00:00:00 2001 From: Cody Brownstein Date: Wed, 8 Feb 2023 15:31:59 -0800 Subject: [PATCH] Add .safetensors as supported file format --- config-default.txt | 2 +- scripts/server.py | 2 +- setup.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/config-default.txt b/config-default.txt index eebb1fe..a541c0d 100644 --- a/config-default.txt +++ b/config-default.txt @@ -94,7 +94,7 @@ PF_UPSCALE_GFPGAN_AMOUNT = 0.0 # visibility of gfpgan face enhancement (0 = off PF_UPSCALE_KEEP_ORG = no # keep the original non-upscaled image (yes/no)? PF_NEG_PROMPT = # if you have a 'catch all' negative prompt you typically use, enter it here -# Set a default .ckpt file here so that whenever you set !CKPT_FILE to nothing (e.g. '!CKPT_FILE = '), this default +# Set a default .ckpt or .safetensors file here so that whenever you set !CKPT_FILE to nothing (e.g. '!CKPT_FILE = '), this default # will be loaded. If you don't set anything here, !CKPT_FILE= will just use whatever happens to be loaded in Auto1111. PF_CKPT_FILE = diff --git a/scripts/server.py b/scripts/server.py index 90585b5..0829cbd 100644 --- a/scripts/server.py +++ b/scripts/server.py @@ -253,7 +253,7 @@ def build_model_reference(control): if control.sdi_models == None: buffer = "Reload this page after Stable Diffusion has finished initializing to see a list of your available models here." else: - buffer += "

These models may be assigned to the !CKPT_FILE directive. Add additional .ckpt files to your Automatic1111 models folder and restart Dream Factory to have them appear here.

\n" + buffer += "

These models may be assigned to the !CKPT_FILE directive. Add additional .ckpt or .safetensors files to your Automatic1111 models folder and restart Dream Factory to have them appear here.

\n" if control.model_trigger_words != None and len(control.model_trigger_words) > 0: if control.config.get('auto_insert_model_trigger') != 'off': buffer += "

Asterisked trigger words will be automatically added " diff --git a/setup.py b/setup.py index d649041..a5cc6d6 100644 --- a/setup.py +++ b/setup.py @@ -185,7 +185,7 @@ def update(shell = False): #if not os.path.exists(checkpoint_path): # os.makedirs(checkpoint_path) - #print('\n\nAll done - don\'t forget to place your model.ckpt file in this directory! : ') + #print('\n\nAll done - don\'t forget to place your model.ckpt or model.safetensors file in this directory! : ') #print(checkpoint_path + '\n') if not os.path.exists('output'): os.makedirs('output')