add lycoris folder

This commit is contained in:
Vladimir Mandic
2023-04-15 12:25:59 -04:00
parent fd51bb90d0
commit e14cba0771
4 changed files with 9 additions and 5 deletions
+3
View File
@@ -60,8 +60,11 @@ def compatibility_args(opts, args):
parser.add_argument("--bsrgan-models-path", type=str, help=argparse.SUPPRESS, default=opts.bsrgan_models_path)
parser.add_argument("--realesrgan-models-path", type=str, help=argparse.SUPPRESS, default=opts.realesrgan_models_path)
parser.add_argument("--clip-models-path", type=str, help=argparse.SUPPRESS, default=opts.clip_models_path)
parser.add_argument("--disable-nan-check", default = True, action='store_true', help=argparse.SUPPRESS)
parser.add_argument("--disable-extension-access", default = False, action='store_true', help=argparse.SUPPRESS)
args = parser.parse_args()
if vars(parser)['_option_string_actions'].get('--lora-dir', None) is not None:
args.lora_dir = opts.lora_dir
if vars(parser)['_option_string_actions'].get('--lyco-dir', None) is not None:
args.lyco_dir = opts.lyco_dir
return args
+4 -4
View File
@@ -86,12 +86,12 @@ dtype_unet = torch.float16
unet_needs_upcast = False
def cond_cast_unet(input):
return input.to(dtype_unet) if unet_needs_upcast else input
def cond_cast_unet(tensor):
return tensor.to(dtype_unet) if unet_needs_upcast else tensor
def cond_cast_float(input):
return input.float() if unet_needs_upcast else input
def cond_cast_float(tensor):
return tensor.float() if unet_needs_upcast else tensor
def randn(seed, shape):
+1
View File
@@ -257,6 +257,7 @@ options_templates.update(options_section(('system-paths', "System Paths"), {
"realesrgan_models_path": OptionInfo(os.path.join(paths.models_path, 'RealESRGAN'), "Path to directory with RealESRGAN model file(s)"),
"clip_models_path": OptionInfo(os.path.join(paths.models_path, 'CLIP'), "Path to directory with CLIP model file(s)"),
"lora_dir": OptionInfo(os.path.join(paths.models_path, 'Lora'), "Path to directory with Lora network(s)"),
"lyco-dir": OptionInfo(os.path.join(paths.models_path, 'LyCORIS'), "Path to directory with LyCORIS network(s)"),
# "gfpgan_model": OptionInfo("", "GFPGAN model file name"),
}))