tori29umai commited on
Commit
d5b61f5
1 Parent(s): 5836c22
Files changed (2) hide show
  1. app.py +2 -2
  2. utils/utils.py +2 -2
app.py CHANGED
@@ -33,8 +33,8 @@ def load_model(lora_dir, cn_dir):
33
  pipe = StableDiffusionXLControlNetImg2ImgPipeline.from_pretrained(
34
  "cagliostrolab/animagine-xl-3.1", controlnet=controlnet, vae=vae, torch_dtype=torch.float16
35
  )
36
- pipe.load_lora_weights(lora_dir, weight_name="style-lineart_02.safetensors", adapter_name="style-lineart_02")
37
- pipe.set_adapters(["style-lineart_02"], adapter_weights=[1.2])
38
  pipe.fuse_lora()
39
  pipe = pipe.to(device)
40
  return pipe
 
33
  pipe = StableDiffusionXLControlNetImg2ImgPipeline.from_pretrained(
34
  "cagliostrolab/animagine-xl-3.1", controlnet=controlnet, vae=vae, torch_dtype=torch.float16
35
  )
36
+ pipe.load_lora_weights(lora_dir, weight_name="sdxl_BW_bold_Line.safetensors", adapter_name="sdxl_BW_bold_Line")
37
+ pipe.set_adapters(["sdxl_BW_bold_Line"], adapter_weights=[1.2])
38
  pipe.fuse_lora()
39
  pipe = pipe.to(device)
40
  return pipe
utils/utils.py CHANGED
@@ -57,10 +57,10 @@ def load_tagger_model(model_dir):
57
 
58
 
59
  def load_lora_model(model_dir):
60
- file_name = 'style-lineart_02.safetensors'
61
  file_path = os.path.join(model_dir, file_name)
62
  if not os.path.exists(file_path):
63
- url = "https://huggingface.co/2vXpSwA7/iroiro-lora/resolve/main/test3/style-lineart_02.safetensors"
64
  response = requests.get(url, allow_redirects=True)
65
  if response.status_code == 200:
66
  with open(file_path, 'wb') as f:
 
57
 
58
 
59
  def load_lora_model(model_dir):
60
+ file_name = 'sdxl_BW_bold_Line.safetensors'
61
  file_path = os.path.join(model_dir, file_name)
62
  if not os.path.exists(file_path):
63
+ url = "https://huggingface.co/tori29umai/lineart/blob/main/sdxl_BW_bold_Line.safetensors"
64
  response = requests.get(url, allow_redirects=True)
65
  if response.status_code == 200:
66
  with open(file_path, 'wb') as f: