Commit Graph
18 Commits
Author SHA1 Message Date
aszc 8d28964831 feat(convert): consolidate into one auto-detecting converter node (#67)
* feat(lcm): convert any full-distill LCM checkpoint

- COREML_CONVERT_LCM gains a ckpt_name input: any checkpoint from the
  checkpoints folder, with the canonical SimianLuo single file as the
  default auto-download entry, so workflows saved before this input
  existed keep the old behavior
- conversion routes through the unified
  coreml_diffusion.convert(model_version=LCM) path; the bespoke
  trace/convert pipeline in lcm/converter.py and the dead
  UNet2DConditionModelLCM wrapper are removed
- output naming via compose_out_name; existing cached LCM .mlpackages
  reconvert once due to the new _se attention suffix in the name
- LCM-LoRA merged checkpoints (plain SD1.5 architecture, no guidance
  embedding) are rejected by the package with a pointer to the standard
  converter node + LCM scheduler
- requires coreml-diffusion>=0.1.4 (generic LCM conversion fix)

Verified against a local ComfyUI checkout: the default entry resolves
the Hugging Face single file and cache-hits a previously converted
.mlpackage exposing timestep_cond; an LCM-LoRA merge raises the
explanatory ValueError.

* feat(convert): consolidate conversion into one auto-detecting node

The standard CoreMLConverter now auto-detects the model version from the
checkpoint (coreml-diffusion>=0.1.5, convert(model_version=None)), so:

- the model_version dropdown is gone — one node converts SD15 / SDXL / SDXL
  refiner / full-distill LCM, the version inferred from the UNet architecture
- the dedicated "Core ML LCM Converter" node, its single-model autodownload,
  and coreml_suite/lcm/nodes.py are removed; the converter UX was previously
  inconsistent (LCM only reachable through a separate autodownload-only node,
  while the standard converter did not list LCM at all)

lcm/utils.py (sampler-side timestep_cond patching) is unchanged — runtime LCM
support still keys off the converted UNet exposing timestep_cond.

diffusers is dropped from the dependencies (no longer imported directly after
the LCM converter removal). The e2e workflow fixture drops its now-invalid
model_version input.

* fix(deps): require coreml-diffusion>=0.1.5, keep requires-python <3.13

The auto-detect consolidation needs convert(model_version=None) from
coreml-diffusion 0.1.5. requires-python stays pinned to <3.13 to match the
library (coremltools-driven); relaxing it past the library's own cap makes the
dependency unresolvable for the 3.13+ range.
2026-06-13 14:11:20 +02:00
aszc-dev 0c78803b25 Base SDXL conversion works 2023-11-24 12:14:15 +01:00
aszc-dev ae9a9874c5 Add Advanced Sampler node 2023-11-24 12:14:15 +01:00
aszc-dev 42ff10cd43 Add node to load LoRAs 2023-11-17 22:55:13 +01:00
aszc-dev a8d2d6ec46 Move lora related code around, remove clip stuff 2023-11-17 22:55:13 +01:00
aszc-dev 45be6761d1 Basic conversion + LoRA support works 2023-11-17 22:55:13 +01:00
aszc-dev 8bcdeab234 Core ML Sampler supports LCM 2023-11-11 03:11:35 +01:00
aszc-dev c9e403b1d8 WIP: LCM Scheduler refactor 2023-11-11 00:19:16 +01:00
aszc-dev 7492f0b486 Extract lcm sampler from lcm sampling node 2023-11-10 13:24:06 +01:00
aszc-dev 1ebd9e72ae Remove Simple LCM Sampler 2023-11-03 01:29:50 +01:00
aszc-dev e22d8187cd Add more advanced LCM Sampler 2023-11-03 01:28:34 +01:00
aszc-dev 1aa5a19b2a Simplify LCM Sampler 2023-11-03 01:27:48 +01:00
aszc-dev 9d509ad8f4 WIP: LCM 2023-11-03 01:27:48 +01:00
aszc-dev 6319d2aedb Add model adapter for unstable compatibility 2023-10-30 11:49:07 +01:00
aszc-dev d0629b4efc Rearrange stuff 2023-10-30 11:15:42 +01:00
aszc-dev 4cd2226148 Add Core ML Sampler 2023-10-29 23:55:18 +01:00
aszc-dev 0a9d20a4b5 Restructure 2023-10-29 14:35:35 +01:00
Adrian Szczepański 24746565bf UNet loader works for fixed sized SD1.5 CoreML models 2023-10-23 15:10:35 +02:00