Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add tcd sampler #2907

Merged
merged 2 commits into from
May 19, 2024
Merged

Conversation

mashb1t
Copy link
Collaborator

@mashb1t mashb1t commented May 12, 2024

closes discussion #2733

adapted code from comfyanonymous/ComfyUI#3370

TODO: check if virtual scheduler tcd is needed for using sampling_base ModelSamplingDiscreteDistilled or if it's better to use sgm_uniform directly without patching

sgm_uniform

image

metadata:

{
"prompt": "man in a bar",
"negative_prompt": "",
"prompt_expansion": "man in a bar, epic, dramatic ambient, detailed, relaxed, full focus, expressive, charismatic, amazing detail, intricate, highly coherent, colorful, surreal, incredible light, sharp, symmetry, holy, fine, polished, extremely complex, color, inspiring, beautiful, elegant, decorative, elaborate, gorgeous, awesome, creative, perfect, wonderful, marvelous, pure",
"styles": "['Fooocus V2', 'Fooocus Enhance', 'Fooocus Sharp']",
"performance": "Speed",
"resolution": "(1024, 1024)",
"guidance_scale": 4,
"sharpness": 2,
"adm_guidance": "(1.5, 0.8, 0.3)",
"base_model": "juggernautXL_v8Rundiffusion.safetensors",
"refiner_model": "None",
"refiner_switch": 0.5,
"sampler": "tcd",
"scheduler": "sgm_uniform",
"seed": "2124872720596715030",
"lora_combined_1": "sd_xl_offset_example-lora_1.0.safetensors : 0.1",
"metadata_scheme": "fooocus",
"version": "Fooocus v2.3.1"
}

virtual tcd scheduler (using sgm_uniform, but using ModelSamplingDiscreteDistilled instead of ModelSamplingDiscrete, same as lcm)

image

metadata:

{
"prompt": "man in a bar",
"negative_prompt": "",
"prompt_expansion": "man in a bar, epic, dramatic ambient, detailed, relaxed, full focus, expressive, charismatic, amazing detail, intricate, highly coherent, colorful, surreal, incredible light, sharp, symmetry, holy, fine, polished, extremely complex, color, inspiring, beautiful, elegant, decorative, elaborate, gorgeous, awesome, creative, perfect, wonderful, marvelous, pure",
"styles": "['Fooocus V2', 'Fooocus Enhance', 'Fooocus Sharp']",
"performance": "Speed",
"resolution": "(1024, 1024)",
"guidance_scale": 4,
"sharpness": 2,
"adm_guidance": "(1.5, 0.8, 0.3)",
"base_model": "juggernautXL_v8Rundiffusion.safetensors",
"refiner_model": "None",
"refiner_switch": 0.5,
"sampler": "tcd",
"scheduler": "tcd",
"seed": "2124872720596715030",
"lora_combined_1": "sd_xl_offset_example-lora_1.0.safetensors : 0.1",
"metadata_scheme": "fooocus",
"version": "Fooocus v2.3.1"
}

adapted code from comfyanonymous/ComfyUI#3370
TODO: check if virtual scheduler tcd is needed for using sampling_base ModelSamplingDiscreteDistilled or if it's better to use sgm_uniform directly without patching
@mashb1t mashb1t requested a review from lllyasviel as a code owner May 12, 2024 17:52
@mashb1t mashb1t added the Size M medium change, isolated, testing with care label May 12, 2024
@mashb1t mashb1t marked this pull request as draft May 12, 2024 18:46
@mashb1t mashb1t added this to the 2.4.0 milestone May 12, 2024
@mashb1t mashb1t marked this pull request as ready for review May 19, 2024 11:05
@mashb1t mashb1t changed the base branch from main to develop May 19, 2024 11:06
@mashb1t mashb1t merged commit 2e2e8f8 into lllyasviel:develop May 19, 2024
csokun pushed a commit to csokun/Fooocus that referenced this pull request Jun 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Size M medium change, isolated, testing with care
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant