When a checkpoint is in a folder, basemodel names display the folder name in metadata and in file name (which results in an error).
For instance, this model: ".SDXL\samaritanCGI_v10.safetensors"
Using this naming method: %time [%seed] [%basemodelname]
results in:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\stable-diffusion\\data\\outputs\\comfyUI\\2024-01-06\\2024-01-06-164431 [298964781848263] [.SDXL\\samaritanCGI_v10.safetensors].jpeg'
Removing %basemodel form the naming method saves the file, but the model name in the metadata is
".SDXL\samaritanCGI_v10.safetensors".
Solution
Change this line in def parse_name(ckpt_name):
path = ckpt_name
to
path = ckpt_name.replace("\\", "/")
Issue
When a checkpoint is in a folder, basemodel names display the folder name in metadata and in file name (which results in an error).
For instance, this model: ".SDXL\samaritanCGI_v10.safetensors"
Using this naming method: %time [%seed] [%basemodelname]
results in:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\stable-diffusion\\data\\outputs\\comfyUI\\2024-01-06\\2024-01-06-164431 [298964781848263] [.SDXL\\samaritanCGI_v10.safetensors].jpeg'
Removing %basemodel form the naming method saves the file, but the model name in the metadata is ".SDXL\samaritanCGI_v10.safetensors".
Solution
Change this line in
def parse_name(ckpt_name)
:path = ckpt_name
topath = ckpt_name.replace("\\", "/")