JuliusVRAR commited on
Commit
af8c1fd
·
1 Parent(s): 31844cd

Dockerfile and patches

Browse files
Files changed (8) hide show
  1. Dockerfile +40 -0
  2. app.py +2 -3
  3. demo.py +158 -0
  4. docker_build.sh +7 -0
  5. patch/node_mappings.py +527 -0
  6. python.py +2 -2
  7. requirements.txt +2 -2
  8. start_docker.sh +10 -0
Dockerfile ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use an official PyTorch image with CUDA support
2
+ FROM nvidia/cuda:12.1.1-cudnn8-runtime-ubuntu22.04
3
+ ARG TKN="hf_"
4
+ # Set environment variables
5
+ ENV DEBIAN_FRONTEND=noninteractive
6
+ ENV PYTHONUNBUFFERED=1
7
+ ENV TZ=Etc/UTC
8
+ ENV HF_TKN=$TKN
9
+ # Install system dependencies
10
+ RUN apt-get update && apt-get install -y \
11
+ git \
12
+ wget \
13
+ curl \
14
+ build-essential \
15
+ libgl1 \
16
+ libglib2.0-0 \
17
+ python3.10 \
18
+ python3.10-dev \
19
+ python3.10-venv \
20
+ python3-pip \
21
+ libxrender1 \
22
+ libxkbcommon-x11-0 \
23
+ libxi6 \
24
+ libsm6 \
25
+ libxext6 \
26
+ libglfw3-dev \
27
+ libgles2-mesa-dev\
28
+ && rm -rf /var/lib/apt/lists/*
29
+ # Setup custom nodes
30
+ WORKDIR /workspace/custom_nodes/
31
+ RUN rm -rf ComfyUI_Comfyroll_CustomNodes
32
+ RUN git clone https://github.com/Suzie1/ComfyUI_Comfyroll_CustomNodes.git
33
+ WORKDIR /workspace/custom_nodes/ComfyUI_Comfyroll_CustomNodes
34
+ # Replace the node_mappings.py file
35
+ RUN rm node_mappings.py
36
+ COPY patch/node_mappings.py /workspace/custom_nodes/ComfyUI_Comfyroll_CustomNodes/
37
+ # Install requirements
38
+ WORKDIR /workspace
39
+ COPY requirements.txt /workspace
40
+ RUN pip install -r requirements.txt
app.py CHANGED
@@ -1,9 +1,8 @@
1
- import spaces
2
  import gradio as gr
3
  import numpy as np
4
  import random
5
  import python
6
- import spaces
7
  import torch
8
  import os
9
  from huggingface_hub import hf_hub_download
@@ -14,7 +13,7 @@ from peft import PeftModel
14
 
15
  dtype = torch.bfloat16
16
  device = "cuda" if torch.cuda.is_available() else "cpu"
17
- token = os.getenv("HUGGINGFACE_TOKEN")
18
 
19
  # good_vae = AutoencoderKL.from_pretrained("black-forest-labs/FLUX.1-dev", subfolder="vae", torch_dtype=dtype, token=token).to(device)
20
  # pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-dev", torch_dtype=dtype, token=token).to(device)
 
1
+ #import spaces
2
  import gradio as gr
3
  import numpy as np
4
  import random
5
  import python
 
6
  import torch
7
  import os
8
  from huggingface_hub import hf_hub_download
 
13
 
14
  dtype = torch.bfloat16
15
  device = "cuda" if torch.cuda.is_available() else "cpu"
16
+ token = os.getenv("HF_TKN")
17
 
18
  # good_vae = AutoencoderKL.from_pretrained("black-forest-labs/FLUX.1-dev", subfolder="vae", torch_dtype=dtype, token=token).to(device)
19
  # pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-dev", torch_dtype=dtype, token=token).to(device)
demo.py ADDED
@@ -0,0 +1,158 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #import spaces
2
+ import gradio as gr
3
+ import numpy as np
4
+ import random
5
+ import python
6
+ import torch
7
+ import os
8
+ from huggingface_hub import hf_hub_download
9
+ from diffusers import DiffusionPipeline, FlowMatchEulerDiscreteScheduler, AutoencoderKL
10
+ from transformers import CLIPTextModel, CLIPTokenizer, T5EncoderModel, T5TokenizerFast
11
+ from live_preview_helpers import calculate_shift, retrieve_timesteps, flux_pipe_call_that_returns_an_iterable_of_images
12
+ from peft import PeftModel
13
+
14
+ dtype = torch.bfloat16
15
+ device = "cuda" if torch.cuda.is_available() else "cpu"
16
+ token = os.getenv("HF_TKN")
17
+
18
+ # good_vae = AutoencoderKL.from_pretrained("black-forest-labs/FLUX.1-dev", subfolder="vae", torch_dtype=dtype, token=token).to(device)
19
+ # pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-dev", torch_dtype=dtype, token=token).to(device)
20
+ torch.cuda.empty_cache()
21
+
22
+ MAX_SEED = np.iinfo(np.int32).max
23
+ MAX_IMAGE_SIZE = 2048 # not used anymore
24
+
25
+ # Bind the custom method
26
+ # pipe.flux_pipe_call_that_returns_an_iterable_of_images = flux_pipe_call_that_returns_an_iterable_of_images.__get__(pipe)
27
+ # python.model_loading()
28
+
29
+
30
+
31
+ def infer(prompt, seed=42, randomize_seed=True, aspect_ratio="4:3 landscape 1152x896", lora_weight="lora_weight_rank_32_alpha_32.safetensors",
32
+ guidance_scale=3.5, num_inference_steps=28, progress=gr.Progress(track_tqdm=True)):
33
+
34
+ # Randomize seed if requested
35
+ if randomize_seed:
36
+ seed = random.randint(0, MAX_SEED)
37
+ generator = torch.Generator().manual_seed(seed)
38
+
39
+ # Load the selected LoRA weight and fuse it
40
+ lora_weight_path = os.path.join("loras", lora_weight)
41
+ # pipe.load_lora_weights(weight_path)
42
+ # pipe.fuse_lora()
43
+ torch.cuda.empty_cache()
44
+ image, seed = python.generate_image(
45
+ prompt,
46
+ guidance_scale,
47
+ aspect_ratio,
48
+ seed,
49
+ num_inference_steps,
50
+ lora_weight,
51
+ )
52
+ # Generate images
53
+ # for img in pipe.flux_pipe_call_that_returns_an_iterable_of_images(
54
+ # prompt=prompt,
55
+ # guidance_scale=guidance_scale,
56
+ # num_inference_steps=num_inference_steps,
57
+ # width=width,
58
+ # height=height,
59
+ # generator=generator,
60
+ # output_type="pil",
61
+ # good_vae=good_vae,
62
+ # ):
63
+ # out_img = img
64
+ return image,seed
65
+
66
+ # Examples for the prompt
67
+ examples = [
68
+ "Photo on a small glass panel. Color. A vintage Autochrome photograph, early 1900s aesthetic depicts four roses in a brown vase with dark background.",
69
+ "Photo on a small glass panel. Color. A depiction of trees with orange leaves and a small path.",
70
+ ]
71
+
72
+ css = """
73
+ #col-container {
74
+ margin: 0 auto;
75
+ max-width: 520px;
76
+ }
77
+ """
78
+
79
+ with gr.Blocks(css=css) as demo:
80
+ with gr.Column(elem_id="col-container"):
81
+ gr.Markdown(f"""# Text2Autochrome demo!
82
+ """)
83
+
84
+ with gr.Row():
85
+ prompt = gr.Text(
86
+ label="Prompt",
87
+ show_label=False,
88
+ max_lines=5,
89
+ placeholder="Enter your prompt",
90
+ container=False,
91
+ )
92
+ run_button = gr.Button("Run", scale=0)
93
+
94
+ result = gr.Image(label="Result", show_label=False)
95
+
96
+ with gr.Accordion("Advanced Settings", open=True):
97
+ seed = gr.Slider(
98
+ label="Seed",
99
+ minimum=0,
100
+ maximum=MAX_SEED,
101
+ step=1,
102
+ value=0,
103
+ )
104
+ randomize_seed = gr.Checkbox(label="Randomize seed", value=True)
105
+
106
+ # Dropdown for aspect ratio selection
107
+ aspect_ratio = gr.Dropdown(
108
+ label="Aspect Ratio",
109
+ choices=["1:1 square 1024x1024", "3:4 portrait 896x1152", "5:8 portrait 832x1216", "9:16 portrait 768x1344", "4:3 landscape 1152x896", "3:2 landscape 1216x832", "16:9 landscape 1344x768"],
110
+ value="4:3 landscape 1152x896",
111
+ interactive=True,
112
+ )
113
+
114
+ # Dropdown for LoRA weight selection
115
+ lora_weight = gr.Dropdown(
116
+ label="LoRA Weight",
117
+ choices=[
118
+ "lora_weight_rank_16_alpha_32_1.safetensors",
119
+ "lora_weight_rank_16_alpha_32_2.safetensors",
120
+ "lora_weight_rank_32_alpha_32.safetensors",
121
+ "lora_weight_rank_32_alpha_64.safetensors",
122
+ ],
123
+ value="lora_weight_rank_16_alpha_32_1.safetensors",
124
+ interactive=True,
125
+ )
126
+
127
+ with gr.Row():
128
+ guidance_scale = gr.Slider(
129
+ label="Guidance Scale",
130
+ minimum=1,
131
+ maximum=25,
132
+ step=0.1,
133
+ value=8.5,
134
+ )
135
+ num_inference_steps = gr.Slider(
136
+ label="Number of inference steps",
137
+ minimum=1,
138
+ maximum=100,
139
+ step=1,
140
+ value=50,
141
+ )
142
+
143
+ gr.Examples(
144
+ examples=examples,
145
+ fn=infer,
146
+ inputs=[prompt],
147
+ outputs=[result, seed],
148
+ cache_examples=False
149
+ )
150
+
151
+ gr.on(
152
+ triggers=[run_button.click, prompt.submit],
153
+ fn=infer,
154
+ inputs=[prompt, seed, randomize_seed, aspect_ratio, lora_weight, guidance_scale, num_inference_steps],
155
+ outputs=[result, seed]
156
+ )
157
+
158
+ demo.launch()
docker_build.sh ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+ IMAGE_NAME=text2autochrome
3
+ TOKEN=hf_
4
+ docker build --build-arg TKN=$TOKEN -f Dockerfile -t $IMAGE_NAME .
5
+
6
+
7
+
patch/node_mappings.py ADDED
@@ -0,0 +1,527 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ from .nodes.nodes_core import *
3
+ from .nodes.nodes_aspect_ratio import *
4
+ from .nodes.nodes_list import *
5
+ from .nodes.nodes_lora import *
6
+ from .nodes.nodes_controlnet import *
7
+ from .nodes.nodes_pipe import *
8
+ from .nodes.nodes_sdxl import *
9
+ from .nodes.nodes_model_merge import *
10
+ from .nodes.nodes_upscale import *
11
+ from .nodes.nodes_xygrid import *
12
+ from .nodes.nodes_legacy import *
13
+
14
+
15
+ from .nodes.nodes_graphics_matplot import *
16
+ from .nodes.nodes_graphics_text import *
17
+ from .nodes.nodes_graphics_layout import *
18
+ from .nodes.nodes_graphics_filter import *
19
+ from .nodes.nodes_graphics_template import *
20
+ from .nodes.nodes_graphics_pattern import *
21
+
22
+
23
+
24
+ from .nodes.nodes_animation_interpolation import *
25
+ from .nodes.nodes_animation_io import *
26
+ from .nodes.nodes_animation_prompt import *
27
+ from .nodes.nodes_animation_schedulers import *
28
+ from .nodes.nodes_animation_schedules import *
29
+ from .nodes.nodes_animation_lists import *
30
+ from .nodes.nodes_animation_utils import *
31
+ from .nodes.nodes_animation_cyclers import *
32
+
33
+
34
+
35
+ from .nodes.nodes_utils_logic import *
36
+ from .nodes.nodes_utils_index import *
37
+ from .nodes.nodes_utils_conversion import *
38
+ from .nodes.nodes_utils_random import *
39
+ from .nodes.nodes_utils_text import *
40
+ from .nodes.nodes_utils_other import *
41
+
42
+
43
+ NODE_CLASS_MAPPINGS = {
44
+ ### Core Nodes
45
+ "CR Image Output": CR_ImageOutput,
46
+ "CR Latent Batch Size": CR_LatentBatchSize,
47
+ "CR Conditioning Mixer": CR_ConditioningMixer,
48
+ "CR Select Model": CR_SelectModel,
49
+ "CR Seed": CR_Seed,
50
+ "CR Prompt Text": CR_PromptText,
51
+ "CR Combine Prompt": CR_CombinePrompt,
52
+ "CR VAE Decode": CR_VAEDecode,
53
+ ### List Nodes
54
+ "CR Text List": CR_TextList,
55
+ "CR Prompt List": CR_PromptList,
56
+ "CR Simple List": CR_SimpleList,
57
+ "CR Float Range List": CR_FloatRangeList,
58
+ "CR Integer Range List": CR_IntegerRangeList,
59
+ "CR Load Text List": CR_LoadTextList,
60
+ "CR Binary To Bit List": CR_BinaryToBitList,
61
+ "CR Text Cycler": CR_TextCycler,
62
+ "CR Value Cycler": CR_ValueCycler,
63
+ ### List IO
64
+ "CR Load Image List": CR_LoadImageList,
65
+ "CR Load Image List Plus": CR_LoadImageListPlus,
66
+ "CR Load GIF As List": CR_LoadGIFAsList,
67
+ "CR Font File List": CR_FontFileList,
68
+ ### List Utils
69
+ "CR Batch Images From List": CR_MakeBatchFromImageList,
70
+ "CR Intertwine Lists" : CR_IntertwineLists,
71
+ "CR Repeater": CR_Repeater,
72
+ "CR XY Product": CR_XYProduct,
73
+ "CR Text List To String": CR_TextListToString,
74
+ ### Aspect Ratio Nodes
75
+ "CR SD1.5 Aspect Ratio": CR_AspectRatioSD15,
76
+ "CR SDXL Aspect Ratio": CR_SDXLAspectRatio,
77
+ "CR Aspect Ratio": CR_AspectRatio,
78
+ "CR Aspect Ratio Banners": CR_AspectRatioBanners,
79
+ "CR Aspect Ratio Social Media": CR_AspectRatioSocialMedia,
80
+ "CR_Aspect Ratio For Print": CR_AspectRatioForPrint,
81
+ ### Legacy Nodes
82
+ "CR Image Size": CR_ImageSize,
83
+ "CR Aspect Ratio SDXL": CR_AspectRatio_SDXL,
84
+ "CR SDXL Prompt Mixer": CR_PromptMixer,
85
+ "CR Seed to Int": CR_SeedToInt,
86
+ ### ControlNet Nodes
87
+ "CR Apply ControlNet": CR_ApplyControlNet,
88
+ "CR Multi-ControlNet Stack": CR_ControlNetStack,
89
+ "CR Apply Multi-ControlNet": CR_ApplyControlNetStack,
90
+ ### LoRA Nodes
91
+ "CR Load LoRA": CR_LoraLoader,
92
+ "CR LoRA Stack": CR_LoRAStack,
93
+ "CR Random LoRA Stack": CR_RandomLoRAStack,
94
+ "CR Random Weight LoRA": CR_RandomWeightLoRA,
95
+ "CR Apply LoRA Stack": CR_ApplyLoRAStack,
96
+ ### Model Merge Nodes
97
+ "CR Apply Model Merge": CR_ApplyModelMerge,
98
+ "CR Model Merge Stack": CR_ModelMergeStack,
99
+ ### Pipe Nodes
100
+ "CR Data Bus In":CR_DataBusIn,
101
+ "CR Data Bus Out":CR_DataBusOut,
102
+ "CR 8 Channel In":CR_8ChannelIn,
103
+ "CR 8 Channel Out":CR_8ChannelOut,
104
+ "CR Module Pipe Loader": CR_ModulePipeLoader,
105
+ "CR Module Input": CR_ModuleInput,
106
+ "CR Module Output": CR_ModuleOutput,
107
+ "CR Image Pipe In": CR_ImagePipeIn,
108
+ "CR Image Pipe Edit": CR_ImagePipeEdit,
109
+ "CR Image Pipe Out": CR_ImagePipeOut,
110
+ "CR Pipe Switch": CR_InputSwitchPipe,
111
+ ### SDXL Nodes
112
+ "CR SDXL Prompt Mix Presets": CR_PromptMixPresets,
113
+ "CR SDXL Style Text": CR_SDXLStyleText,
114
+ "CR SDXL Base Prompt Encoder": CR_SDXLBasePromptEncoder,
115
+ ### Upscale Nodes
116
+ "CR Multi Upscale Stack": CR_MultiUpscaleStack,
117
+ "CR Upscale Image": CR_UpscaleImage,
118
+ "CR Apply Multi Upscale": CR_ApplyMultiUpscale,
119
+ ### XY Grid Nodes
120
+ "CR XY List": CR_XYList,
121
+ "CR XY Interpolate": CR_XYInterpolate,
122
+ "CR XY From Folder": CR_XYFromFolder,
123
+ "CR XY Save Grid Image": CR_XYSaveGridImage,
124
+ "CR XY Index": CR_XYIndex,
125
+ #"CR XYZ Index": CR_XYZIndex,
126
+ ### Graphics Pattern
127
+ "CR Halftone Grid": CR_HalftoneGrid,
128
+ "CR Color Bars": CR_ColorBars,
129
+ "CR Style Bars": CR_StyleBars,
130
+ "CR Checker Pattern": CR_CheckerPattern,
131
+ "CR Polygons": CR_Polygons,
132
+ "CR Color Gradient": CR_ColorGradient,
133
+ "CR Radial Gradient": CR_RadialGradient,
134
+ "CR Starburst Lines": CR_StarburstLines,
135
+ "CR Starburst Colors": CR_StarburstColors,
136
+ "CR Simple Binary Pattern": CR_BinaryPatternSimple,
137
+ "CR Binary Pattern": CR_BinaryPattern,
138
+ ### Graphics Shape
139
+ "CR Draw Shape": CR_DrawShape,
140
+ "CR Draw Pie": CR_DrawPie,
141
+ "CR Random Shape Pattern": CR_RandomShapePattern,
142
+ ### Graphics Text
143
+ "CR Overlay Text": CR_OverlayText,
144
+ "CR Draw Text": CR_DrawText,
145
+ "CR Mask Text": CR_MaskText,
146
+ "CR Composite Text": CR_CompositeText,
147
+ #"CR Arabic Text RTL": CR_ArabicTextRTL,
148
+ "CR Simple Text Watermark": CR_SimpleTextWatermark,
149
+ "CR Select Font": CR_SelectFont,
150
+ ### Graphics Filter
151
+ "CR Halftone Filter": CR_HalftoneFilter,
152
+ "CR Color Tint": CR_ColorTint,
153
+ "CR Vignette Filter": CR_VignetteFilter,
154
+ ### Graphics Layout
155
+ "CR Page Layout": CR_PageLayout,
156
+ "CR Image Panel": CR_ImagePanel,
157
+ "CR Image Grid Panel": CR_ImageGridPanel,
158
+ "CR Image Border": CR_ImageBorder,
159
+ "CR Feathered Border": CR_FeatheredBorder,
160
+ "CR Simple Text Panel": CR_SimpleTextPanel,
161
+ "CR Color Panel": CR_ColorPanel,
162
+ "CR Overlay Transparent Image": CR_OverlayTransparentImage,
163
+ "CR Half Drop Panel": CR_HalfDropPanel,
164
+ "CR Diamond Panel": CR_DiamondPanel,
165
+ #"CR Simple Titles": CR_SimpleTitles,
166
+ ### Graphics Template
167
+ "CR Simple Meme Template": CR_SimpleMemeTemplate,
168
+ "CR Simple Banner": CR_SimpleBanner,
169
+ "CR Comic Panel Templates": CR_ComicPanelTemplates,
170
+ "CR Simple Image Compare": CR_SimpleImageCompare,
171
+ "CR Thumbnail Preview": CR_ThumbnailPreview,
172
+ "CR Seamless Checker": CR_SeamlessChecker,
173
+ ### Utils Logic
174
+ "CR Image Input Switch": CR_ImageInputSwitch,
175
+ "CR Image Input Switch (4 way)": CR_ImageInputSwitch4way,
176
+ "CR Latent Input Switch": CR_LatentInputSwitch,
177
+ "CR Conditioning Input Switch": CR_ConditioningInputSwitch,
178
+ "CR Clip Input Switch": CR_ClipInputSwitch,
179
+ "CR Model Input Switch": CR_ModelInputSwitch,
180
+ "CR ControlNet Input Switch": CR_ControlNetInputSwitch,
181
+ "CR VAE Input Switch": CR_VAEInputSwitch,
182
+ "CR Text Input Switch": CR_TextInputSwitch,
183
+ "CR Text Input Switch (4 way)": CR_TextInputSwitch4way,
184
+ "CR Switch Model and CLIP": CR_ModelAndCLIPInputSwitch,
185
+ ### Utils Process
186
+ "CR Batch Process Switch": CR_BatchProcessSwitch,
187
+ "CR Img2Img Process Switch": CR_Img2ImgProcessSwitch,
188
+ "CR Hires Fix Process Switch": CR_HiResFixProcessSwitch,
189
+ ### Utils Index
190
+ "CR Index": CR_Index,
191
+ "CR Index Increment": CR_IncrementIndex,
192
+ "CR Index Multiply": CR_MultiplyIndex,
193
+ "CR Index Reset": CR_IndexReset,
194
+ "CR Trigger": CR_Trigger,
195
+ ### Utils Conversion
196
+ "CR String To Number": CR_StringToNumber,
197
+ "CR String To Combo": CR_StringToCombo,
198
+ "CR Float To String": CR_FloatToString,
199
+ "CR Float To Integer": CR_FloatToInteger,
200
+ "CR Integer To String": CR_IntegerToString,
201
+ "CR String To Boolean": CR_StringToBoolean,
202
+ ### Utils Random
203
+ "CR Random Hex Color": CR_RandomHexColor,
204
+ "CR Random RGB": CR_RandomRGB,
205
+ "CR Random Multiline Values": CR_RandomMultilineValues,
206
+ "CR Random Multiline Colors": CR_RandomMultilineColors,
207
+ "CR Random RGB Gradient": CR_RandomRGBGradient,
208
+ "CR Random Panel Codes": CR_RandomPanelCodes,
209
+ ### Utils Text
210
+ "CR Text": CR_Text,
211
+ "CR Multiline Text": CR_MultilineText,
212
+ "CR Split String": CR_SplitString,
213
+ "CR Text Concatenate": CR_TextConcatenate,
214
+ "CR Text Replace": CR_TextReplace,
215
+ "CR Text Length": CR_TextLength,
216
+ "CR Text Operation": CR_TextOperation,
217
+ "CR Text Blacklist": CR_TextBlacklist,
218
+ "CR Save Text To File": CR_SaveTextToFile,
219
+ ### Utils Conditional
220
+ "CR Set Value On Boolean": CR_SetValueOnBoolean,
221
+ "CR Set Value On Binary": CR_SetValueOnBinary,
222
+ "CR Set Value on String": CR_SetValueOnString,
223
+ "CR Set Switch From String": CR_SetSwitchFromString,
224
+ ### Utils Other
225
+ "CR Value": CR_Value,
226
+ "CR Integer Multiple": CR_IntegerMultipleOf,
227
+ "CR Clamp Value": CR_ClampValue,
228
+ "CR Math Operation": CR_MathOperation,
229
+ "CR Get Parameter From Prompt": CR_GetParameterFromPrompt,
230
+ "CR Select Resize Method": CR_SelectResizeMethod,
231
+ "CR Select ISO Size": CR_SelectISOSize,
232
+ ### Animation Nodes
233
+ # Schedules
234
+ "CR Simple Schedule": CR_SimpleSchedule,
235
+ "CR Central Schedule": CR_CentralSchedule,
236
+ "CR Combine Schedules": CR_CombineSchedules,
237
+ "CR Output Schedule To File": CR_OutputScheduleToFile,
238
+ "CR Load Schedule From File": CR_LoadScheduleFromFile,
239
+ "CR Schedule Input Switch": Comfyroll_ScheduleInputSwitch,
240
+ "CR Bit Schedule": CR_BitSchedule,
241
+ # Schedulers
242
+ "CR Simple Value Scheduler": CR_SimpleValueScheduler,
243
+ "CR Simple Text Scheduler": CR_SimpleTextScheduler,
244
+ "CR Value Scheduler": CR_ValueScheduler,
245
+ "CR Text Scheduler": CR_TextScheduler,
246
+ "CR Load Scheduled Models": CR_LoadScheduledModels,
247
+ "CR Load Scheduled LoRAs": CR_LoadScheduledLoRAs,
248
+ "CR Prompt Scheduler": CR_PromptScheduler,
249
+ "CR Simple Prompt Scheduler": CR_SimplePromptScheduler,
250
+ # Prompt
251
+ "CR Keyframe List": CR_KeyframeList,
252
+ #"CR Load Prompt Style": CR_LoadPromptStyle,
253
+ "CR Encode Scheduled Prompts": CR_EncodeScheduledPrompts,
254
+ # Interpolation
255
+ "CR Gradient Float": CR_GradientFloat,
256
+ "CR Gradient Integer": CR_GradientInteger,
257
+ "CR Increment Float": CR_IncrementFloat,
258
+ "CR Increment Integer": CR_IncrementInteger,
259
+ "CR Interpolate Latents": CR_InterpolateLatents,
260
+ # Utils
261
+ "CR Debatch Frames": CR_DebatchFrames,
262
+ "CR Current Frame": CR_CurrentFrame,
263
+ #"CR Input Text List": CR_InputTextList,
264
+ # IO
265
+ "CR Load Animation Frames": CR_LoadAnimationFrames,
266
+ "CR Load Flow Frames": CR_LoadFlowFrames,
267
+ "CR Output Flow Frames": CR_OutputFlowFrames,
268
+ ### Legacy
269
+ # Note: CR Prompt List and CR Text List names have been reused,
270
+ # so the old versions of these nodes are no longer available
271
+ "CR Prompt List Keyframes": CR_PromptListKeyframes,
272
+ "CR Simple Prompt List": CR_SimplePromptList,
273
+ "CR Simple Prompt List Keyframes": CR_SimplePromptListKeyframes,
274
+ "CR Cycle Models": CR_CycleModels,
275
+ "CR Cycle LoRAs": CR_CycleLoRAs,
276
+ "CR Cycle Text": CR_CycleText,
277
+ "CR Cycle Text Simple": CR_CycleTextSimple,
278
+ "CR Cycle Images": CR_CycleImages,
279
+ "CR Cycle Images Simple": CR_CycleImagesSimple,
280
+ "CR Model List": CR_ModelList,
281
+ "CR LoRA List": CR_LoRAList,
282
+ "CR Text List Simple": CR_TextListSimple,
283
+ "CR Image List": CR_ImageList,
284
+ "CR Image List Simple": CR_ImageListSimple,
285
+ }
286
+
287
+ NODE_DISPLAY_NAME_MAPPINGS = {
288
+ ### Core Nodes
289
+ "CR Image Output": "💾 CR Image Output",
290
+ "CR Integer Multiple": "⚙️ CR Integer Multiple",
291
+ "CR Latent Batch Size": "⚙️ CR Latent Batch Size",
292
+ "CR Seed": "🌱 CR Seed",
293
+ "CR Value": "⚙️ CR Value",
294
+ "CR Conditioning Mixer": "⚙️ CR Conditioning Mixer",
295
+ "CR Select Model": "🔮 CR Select Model",
296
+ "CR Prompt Text": "⚙️ CR Prompt Text",
297
+ "CR Combine Prompt": "⚙️ CR Combine Prompt",
298
+ "CR VAE Decode": "⚙️ CR VAE Decode",
299
+ ### List Nodes
300
+ "CR Text List": "📜 CR Text List",
301
+ "CR Prompt List": "📜 CR Prompt List",
302
+ "CR Simple List": "📜 CR Simple List",
303
+ "CR Float Range List": "📜 CR Float Range List",
304
+ "CR Integer Range List": "📜 CR Integer Range List",
305
+ "CR Load Value List": "📜 CR Load Value List",
306
+ "CR Load Text List": "📜 CR Load Text List",
307
+ "CR Binary To Bit List": "📜 CR Binary To Bit List",
308
+ "CR Text Cycler": "📜 CR Text Cycler",
309
+ "CR Value Cycler": "📜 CR Value Cycler",
310
+ ### List IO
311
+ "CR Load Image List": "⌨️ CR Load Image List",
312
+ "CR Load Image List Plus": "⌨️ CR Load Image List Plus",
313
+ "CR Load GIF As List": "⌨️ CR Load GIF As List",
314
+ "CR Font File List": "⌨️ CR Font File List",
315
+ ### List Utils
316
+ "CR Batch Images From List": "🛠️ CR Batch Images From List",
317
+ "CR Intertwine Lists" : "🛠️ CR Intertwine Lists",
318
+ "CR Repeater": "🛠️ CR Repeater",
319
+ "CR XY Product": "🛠️ CR XY Product",
320
+ "CR Text List To String": "🛠️ CR Text List To String",
321
+ ### Aspect Ratio Nodes
322
+ "CR SD1.5 Aspect Ratio": "🔳 CR SD1.5 Aspect Ratio",
323
+ "CR SDXL Aspect Ratio": "🔳 CR SDXL Aspect Ratio",
324
+ "CR Aspect Ratio": "🔳 CR Aspect Ratio",
325
+ "CR Aspect Ratio Banners": "🔳 CR Aspect Ratio Banners",
326
+ "CR Aspect Ratio Social Media": "🔳 CR Aspect Ratio Social Media",
327
+ "CR_Aspect Ratio For Print": "🔳 CR_Aspect Ratio For Print",
328
+ ### Legacy Nodes
329
+ "CR Image Size": "CR Image Size (Legacy)",
330
+ "CR Aspect Ratio SDXL": "CR Aspect Ratio SDXL (Legacy)",
331
+ "CR SDXL Prompt Mixer": "CR SDXL Prompt Mixer (Legacy)",
332
+ "CR Seed to Int": "CR Seed to Int (Legacy)",
333
+ ### ControlNet Nodes
334
+ "CR Apply ControlNet": "🕹️ CR Apply ControlNet",
335
+ "CR Multi-ControlNet Stack": "🕹️ CR Multi-ControlNet Stack",
336
+ "CR Apply Multi-ControlNet": "🕹️ CR Apply Multi-ControlNet",
337
+ ### LoRA Nodes
338
+ "CR Load LoRA": "💊 CR Load LoRA",
339
+ "CR LoRA Stack": "💊 CR LoRA Stack",
340
+ "CR Random LoRA Stack": "💊 CR Random LoRA Stack",
341
+ "CR Random Weight LoRA": "💊 CR Random Weight LoRA",
342
+ "CR Apply LoRA Stack": "💊 CR Apply LoRA Stack",
343
+ ### Model Merge Nodes
344
+ "CR Apply Model Merge": "⛏️ CR Apply Model Merge",
345
+ "CR Model Merge Stack": "⛏️ CR Model Merge Stack",
346
+ ### Pipe Nodes
347
+ "CR Data Bus In": "🚌 CR Data Bus In",
348
+ "CR Data Bus Out": "🚌 CR Data Bus Out",
349
+ "CR 8 Channel In": "🚌 CR 8 Channel In",
350
+ "CR 8 Channel Out": "🚌 CR 8 Channel Out",
351
+ "CR Module Pipe Loader": "✈️ CR Module Pipe Loader",
352
+ "CR Module Input": "✈️ CR Module Input",
353
+ "CR Module Output": "✈️ CR Module Output",
354
+ "CR Image Pipe In": "🛩 CR Image Pipe In",
355
+ "CR Image Pipe Edit": "🛩️ CR Image Pipe Edit",
356
+ "CR Image Pipe Out": "🛩️ CR Image Pipe Out",
357
+ "CR Pipe Switch": "🔀️ CR Pipe Switch",
358
+ ### SDXL Nodes
359
+ "CR SDXL Prompt Mix Presets": "🌟 CR SDXL Prompt Mix Presets",
360
+ "CR SDXL Style Text": "🌟 CR SDXL Style Text",
361
+ "CR SDXL Base Prompt Encoder": "🌟 CR SDXL Base Prompt Encoder",
362
+ ### Upscale Nodes
363
+ "CR Multi Upscale Stack": "🔍 CR Multi Upscale Stack",
364
+ "CR Upscale Image": "🔍 CR Upscale Image",
365
+ "CR Apply Multi Upscale": "🔍 CR Apply Multi Upscale",
366
+ ### XY Grid Nodes
367
+ "CR XY List": "📉 CR XY List",
368
+ "CR XY Interpolate": "📉 CR XY Interpolate",
369
+ "CR XY Index": "📉 CR XY Index",
370
+ "CR XY From Folder": "📉 CR XY From Folder",
371
+ "CR XY Save Grid Image": "📉 CR XY Save Grid Image",
372
+ ### Graphics Pattern
373
+ "CR Halftone Grid" : "🟫 CR Halftone Grid",
374
+ "CR Color Bars" : "🟫 CR Color Bars",
375
+ "CR Style Bars" : "🟪 CR Style Bars",
376
+ "CR Checker Pattern": "🟦 CR Checker Pattern",
377
+ "CR Polygons": "🟩 CR Polygons",
378
+ "CR Color Gradient": "🟨 CR Color Gradient",
379
+ "CR Radial Gradient": "🟨 CR Radial Gradient",
380
+ "CR Starburst Lines": "🟧 CR Starburst Lines",
381
+ "CR Starburst Colors": "🟧 CR Starburst Colors",
382
+ "CR Simple Binary Pattern": "🟥 CR Simple Binary Pattern",
383
+ "CR Binary Pattern": "🟥 CR Binary Pattern",
384
+ ### Graphics Shape
385
+ "CR Draw Shape": "🟡 CR Draw Shape",
386
+ "CR Draw Pie": "🟢 CR Draw Pie",
387
+ "CR Random Shape Pattern": "🔵 CR Random Shape Pattern",
388
+ ### Graphics Text
389
+ "CR Overlay Text": "🔤 CR Overlay Text",
390
+ "CR Draw Text": "🔤️ CR Draw Text",
391
+ "CR Mask Text": "🔤️ CR Mask Text",
392
+ "CR Composite Text": "🔤️ CR Composite Text",
393
+ "CR Simple Text Watermark": "🔤️ CR Simple Text Watermark",
394
+ "CR Select Font": "🔤️ CR Select Font",
395
+ ### Graphics Filter
396
+ "CR Halftone Filter": "🎨 Halftone Filter",
397
+ "CR Color Tint": "🎨 CR Color Tint",
398
+ "CR Vignette Filter": "🎨 CR Vignette Filter",
399
+ ### Graphics Layout
400
+ "CR Image Panel": "🌁 CR Image Panel",
401
+ "CR Image Grid Panel": "🌁 CR Image Grid Panel",
402
+ "CR Simple Text Panel": "🌁 CR Simple Text Panel",
403
+ "CR Color Panel": "🌁 CR Color Panel",
404
+ "CR Half Drop Panel": "🌁 CR Half Drop Panel",
405
+ "CR Diamond Panel": "🌁 CR Diamond Panel",
406
+ "CR Page Layout": "🌁 CR Page Layout",
407
+ "CR Image Border": "🌁 CR Image Border",
408
+ "CR Feathered Border": "🌁 CR Feathered Border",
409
+ "CR Overlay Transparent Image": "🌁 CR Overlay Transparent Image",
410
+ ### Graphics Template
411
+ "CR Simple Meme Template": "📱 CR Simple Meme Template",
412
+ "CR Simple Banner": "📱 CR Simple Banner",
413
+ "CR Comic Panel Templates": "📱 CR Comic Panel Templates",
414
+ "CR Simple Image Compare": "📱 CR Simple Image Compare",
415
+ "CR Thumbnail Preview": "📱 CR Thumbnail Preview",
416
+ "CR Seamless Checker": "📱 CR Seamless Checker",
417
+ ### Utils Logic
418
+ "CR Image Input Switch": "🔀 CR Image Input Switch",
419
+ "CR Image Input Switch (4 way)": "🔀 CR Image Input Switch (4 way)",
420
+ "CR Latent Input Switch": "🔀 CR Latent Input Switch",
421
+ "CR Conditioning Input Switch": "🔀 CR Conditioning Input Switch",
422
+ "CR Clip Input Switch": "🔀 CR Clip Input Switch",
423
+ "CR Model Input Switch": "🔀 CR Model Input Switch",
424
+ "CR ControlNet Input Switch": "🔀 CR ControlNet Input Switch",
425
+ "CR VAE Input Switch": "🔀 CR VAE Input Switch",
426
+ "CR Text Input Switch": "🔀 CR Text Input Switch",
427
+ "CR Text Input Switch (4 way)": "🔀 CR Text Input Switch (4 way)",
428
+ "CR Switch Model and CLIP": "🔀 CR Switch Model and CLIP",
429
+ ### Utils Process
430
+ "CR Batch Process Switch": "🔂 CR Batch Process Switch",
431
+ "CR Img2Img Process Switch": "🔂 CR Img2Img Process Switch",
432
+ "CR Hires Fix Process Switch": "🔂 CR Hires Fix Process Switch",
433
+ ### Utils Index
434
+ "CR Index":"🔢 CR Index",
435
+ "CR Index Increment": "🔢 CR Index Increment",
436
+ "CR Index Multiply": "🔢 CR Index Multiply",
437
+ "CR Index Reset": "🔢 CR Index Reset",
438
+ "CR Trigger": "🔢 CR Trigger",
439
+ ### Utils Conversion
440
+ "CR String To Number": "🔧 CR String To Number",
441
+ "CR String To Combo": "🔧 CR String To Combo",
442
+ "CR Float To String": "🔧 CR Float To String",
443
+ "CR Float To Integer": "🔧 CR Float To Integer",
444
+ "CR Integer To String": "🔧 CR Integer To String",
445
+ "CR String To Boolean": "🔧 CR String To Boolean",
446
+ ### Utils Random
447
+ "CR Random Hex Color": "🎲 CR Random Hex Color",
448
+ "CR Random RGB": "🎲 CR Random RGB",
449
+ "CR Random Multiline Values": "🎲 CR Random Multiline Values",
450
+ "CR Random Multiline Colors": "🎲 CR Random Multiline Colors",
451
+ "CR Random RGB Gradient": "🎲 CR Random RGB Gradient",
452
+ "CR Random Panel Codes": "🎲 CR Random Panel Codes",
453
+ ### Utils Text
454
+ "CR Text": "🔤 CR Text",
455
+ "CR Multiline Text": "🔤 CR Multiline Text",
456
+ "CR Split String": "🔤 CR Split String",
457
+ "CR Text Concatenate": "🔤 CR Text Concatenate",
458
+ "CR Text Replace": "🔤 CR Text Replace",
459
+ "CR Text Blacklist": "🔤 Text Blacklist",
460
+ "CR Text Length": "🔤 CR Text Length",
461
+ "CR Text Operation": "🔤 CR Text Operation",
462
+ "CR Save Text To File": "🔤 CR Save Text To File",
463
+ ### Utils Conditional
464
+ "CR Set Value On Boolean": "⚙️ CR Set Value On Boolean",
465
+ "CR Set Value On Binary": "⚙️ CR Set Value On Binary",
466
+ "CR Set Value on String": "⚙️ CR Set Value on String",
467
+ "CR Set Switch From String": "⚙️ CR Set Switch From String",
468
+ ### Utils Other
469
+ "CR Integer Multiple": "⚙️ CR Integer Multiple",
470
+ "CR Value": "⚙️ CR Value",
471
+ "CR Clamp Value": "⚙️ CR Clamp Value",
472
+ "CR Math Operation": "⚙️ CR Math Operation",
473
+ "CR Get Parameter From Prompt": "⚙️ CR Get Parameter From Prompt",
474
+ "CR Select Resize Method": "⚙️ CR Select Resize Method",
475
+ "CR Select ISO Size": "⚙️ CR Select ISO Size",
476
+ ### Animation Nodes
477
+ # Schedules
478
+ "CR Simple Schedule": "📋 CR Simple Schedule",
479
+ "CR Central Schedule": "📋 CR Central Schedule",
480
+ "CR Combine Schedules": "📋 CR Combine Schedules",
481
+ "CR Output Schedule To File": "📋 CR Output Schedule To File",
482
+ "CR Load Schedule From File": "📋 CR Load Schedule From File",
483
+ "CR Schedule Input Switch": "📋 CR Schedule Input Switch",
484
+ "CR Bit Schedule": "📋 CR Bit Schedule",
485
+ # Schedulers
486
+ "CR Simple Value Scheduler": "📑 CR Simple Value Scheduler",
487
+ "CR Simple Text Scheduler": "📑 CR Simple Text Scheduler",
488
+ "CR Value Scheduler": "📑 CR Value Scheduler",
489
+ "CR Text Scheduler": "📑 CR Text Scheduler",
490
+ "CR Load Scheduled Models": "📑 CR Load Scheduled Models",
491
+ "CR Load Scheduled LoRAs": "📑 CR Load Scheduled LoRAs",
492
+ "CR Prompt Scheduler": "📑 CR Prompt Scheduler",
493
+ "CR Simple Prompt Scheduler": "📑 CR Simple Prompt Scheduler",
494
+ # Prompt
495
+ "CR Keyframe List": "📝 CR Keyframe List",
496
+ #"CR Load Prompt Style": "📝 CR Load Prompt Style",
497
+ "CR Encode Scheduled Prompts": "📝 CR Encode Scheduled Prompts",
498
+ # Interpolation
499
+ "CR Gradient Float": "🔢 CR Gradient Float",
500
+ "CR Gradient Integer": "🔢 CR Gradient Integer",
501
+ "CR Increment Float": "🔢 CR Increment Float",
502
+ "CR Increment Integer": "🔢 CR Increment Integer",
503
+ "CR Interpolate Latents": "🔢 CR Interpolate Latents",
504
+ # Utils
505
+ "CR Debatch Frames": "🛠️ CR Debatch Frames",
506
+ "CR Current Frame": "🛠️ CR Current Frame",
507
+ # IO
508
+ "CR Load Animation Frames": "⌨️ CR Load Animation Frames",
509
+ "CR Load Flow Frames": "⌨️ CR Load Flow Frames",
510
+ "CR Output Flow Frames": "⌨️ CR Output Flow Frames",
511
+ ### Legacy
512
+ "CR Prompt List Keyframes": "CR Prompt List Keyframes (Legacy)",
513
+ "CR Simple Prompt List": "CR Simple Prompt List (Legacy)",
514
+ "CR Simple Prompt List Keyframes": "CR Simple Prompt List Keyframes (Legacy)",
515
+ "CR Cycle Models": "CR Cycle Models (Legacy)",
516
+ "CR Cycle LoRAs": "CR Cycle LoRAs (Legacy)",
517
+ "CR Cycle Text": "CR Cycle Text (Legacy)",
518
+ "CR Cycle Text Simple": "CR Cycle Text Simple (Legacy)",
519
+ "CR Cycle Images": "CR Cycle Images (Legacy)",
520
+ "CR Cycle Images Simple": "CR Cycle Images Simple (Legacy)",
521
+ "CR Model List": "CR Model List (Legacy)",
522
+ "CR LoRA List": "CR LoRA List (Legacy)",
523
+ "CR Text List Simple": "CR Text List Simple (Legacy)",
524
+ "CR Image List": "CR Image List (Legacy)",
525
+ "CR Image List Simple": "CR Image List Simple (Legacy)",
526
+ "CR Input Text List": "CR Input Text List (Legacy)",
527
+ }
python.py CHANGED
@@ -3,7 +3,7 @@ import random
3
  import sys
4
  from typing import Sequence, Mapping, Any, Union
5
  import torch
6
- import spaces
7
  import numpy as np
8
  from PIL import Image
9
  # from comfy import model_management
@@ -19,7 +19,7 @@ import numpy as np
19
  import time
20
 
21
  from huggingface_hub import hf_hub_download
22
- token = os.getenv("HUGGINGFACE_TOKEN")
23
  # Merge both mappings
24
  NODE_CLASS_MAPPINGS = {**NODE_CLASS_MAPPINGS_1, **NODE_CLASS_MAPPINGS_2, **NODE_CLASS_MAPPINGS_3, **NODE_CLASS_MAPPINGS_4, **NODE_CLASS_MAPPINGS_5, **NODE_CLASS_MAPPINGS_6}
25
  hf_hub_download(repo_id="black-forest-labs/FLUX.1-dev", filename="flux1-dev.safetensors", local_dir="models/unet", token = token)
 
3
  import sys
4
  from typing import Sequence, Mapping, Any, Union
5
  import torch
6
+ #import spaces
7
  import numpy as np
8
  from PIL import Image
9
  # from comfy import model_management
 
19
  import time
20
 
21
  from huggingface_hub import hf_hub_download
22
+ token = os.getenv("HF_TKN")
23
  # Merge both mappings
24
  NODE_CLASS_MAPPINGS = {**NODE_CLASS_MAPPINGS_1, **NODE_CLASS_MAPPINGS_2, **NODE_CLASS_MAPPINGS_3, **NODE_CLASS_MAPPINGS_4, **NODE_CLASS_MAPPINGS_5, **NODE_CLASS_MAPPINGS_6}
25
  hf_hub_download(repo_id="black-forest-labs/FLUX.1-dev", filename="flux1-dev.safetensors", local_dir="models/unet", token = token)
requirements.txt CHANGED
@@ -16,13 +16,13 @@ Pillow
16
  scipy
17
  tqdm
18
  psutil
19
- #non essential dependencies:
20
  kornia>=0.7.1
21
  spandrel
22
  soundfile
23
  av
24
  accelerate
25
- git+https://github.com/huggingface/diffusers.git
26
  xformers
27
  sentencepiece
28
  peft==0.15.0
 
 
16
  scipy
17
  tqdm
18
  psutil
 
19
  kornia>=0.7.1
20
  spandrel
21
  soundfile
22
  av
23
  accelerate
24
+ diffusers==0.33.1
25
  xformers
26
  sentencepiece
27
  peft==0.15.0
28
+ gradio==5.32.0
start_docker.sh ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+ # Start docker container in WSL to debug locally
3
+ WORKSPACE=$PWD
4
+ NAME=T2A
5
+ IMAGE_NAME=text2autochrome
6
+ docker run --gpus all -it -d --rm \
7
+ --name=$NAME \
8
+ -v $WORKSPACE:/workspace \
9
+ $IMAGE_NAME
10
+