fffiloni commited on
Commit
a828900
·
verified ·
1 Parent(s): 45adfa2

Update gradio_ui.py

Browse files
Files changed (1) hide show
  1. gradio_ui.py +8 -1
gradio_ui.py CHANGED
@@ -22,14 +22,21 @@ from clip_interrogator import Interrogator, Config, list_clip_models
22
 
23
  from huggingface_hub import snapshot_download
24
 
25
- # Ensure 'checkpoint' directory exists
26
  os.makedirs("sdxl_light_caption_output", exist_ok=True)
 
27
 
28
  snapshot_download(
29
  repo_id = 'nickpai/sdxl_light_caption_output',
30
  local_dir = 'sdxl_light_caption_output'
31
  )
32
 
 
 
 
 
 
 
33
  def apply_color(image: PIL.Image.Image, color_map: PIL.Image.Image) -> PIL.Image.Image:
34
  # Convert input images to LAB color space
35
  image_lab = image.convert('LAB')
 
22
 
23
  from huggingface_hub import snapshot_download
24
 
25
+ # Download colorization models
26
  os.makedirs("sdxl_light_caption_output", exist_ok=True)
27
+ os.makedirs("sdxl_light_custom_caption_output", exist_ok=True)
28
 
29
  snapshot_download(
30
  repo_id = 'nickpai/sdxl_light_caption_output',
31
  local_dir = 'sdxl_light_caption_output'
32
  )
33
 
34
+ snapshot_download(
35
+ repo_id = 'nickpai/sdxl_light_custom_caption_output',
36
+ local_dir = 'sdxl_light_custom_caption_output'
37
+ )
38
+
39
+
40
  def apply_color(image: PIL.Image.Image, color_map: PIL.Image.Image) -> PIL.Image.Image:
41
  # Convert input images to LAB color space
42
  image_lab = image.convert('LAB')