Files
ComfyUI-Tween/__init__.py
Ethanfel 9f66233b53 Add VFI Optimizer node for auto-tuning hardware settings
Benchmarks the user's GPU with the actual model and resolution via a
single calibration frame pair, then outputs optimal batch_size,
chunk_size, keep_device, all_on_gpu, and clear_cache_after_n_frames
as a connectable VFI_SETTINGS type. All 8 Interpolate/SegmentInterpolate
nodes accept the new optional settings input — existing workflows
without the optimizer work unchanged.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-27 22:15:48 +01:00

42 lines
1.7 KiB
Python

from .nodes import (
LoadBIMVFIModel, BIMVFIInterpolate, BIMVFISegmentInterpolate, TweenConcatVideos,
LoadEMAVFIModel, EMAVFIInterpolate, EMAVFISegmentInterpolate,
LoadSGMVFIModel, SGMVFIInterpolate, SGMVFISegmentInterpolate,
LoadGIMMVFIModel, GIMMVFIInterpolate, GIMMVFISegmentInterpolate,
VFIOptimizer,
)
NODE_CLASS_MAPPINGS = {
"LoadBIMVFIModel": LoadBIMVFIModel,
"BIMVFIInterpolate": BIMVFIInterpolate,
"BIMVFISegmentInterpolate": BIMVFISegmentInterpolate,
"TweenConcatVideos": TweenConcatVideos,
"LoadEMAVFIModel": LoadEMAVFIModel,
"EMAVFIInterpolate": EMAVFIInterpolate,
"EMAVFISegmentInterpolate": EMAVFISegmentInterpolate,
"LoadSGMVFIModel": LoadSGMVFIModel,
"SGMVFIInterpolate": SGMVFIInterpolate,
"SGMVFISegmentInterpolate": SGMVFISegmentInterpolate,
"LoadGIMMVFIModel": LoadGIMMVFIModel,
"GIMMVFIInterpolate": GIMMVFIInterpolate,
"GIMMVFISegmentInterpolate": GIMMVFISegmentInterpolate,
"VFIOptimizer": VFIOptimizer,
}
NODE_DISPLAY_NAME_MAPPINGS = {
"LoadBIMVFIModel": "Load BIM-VFI Model",
"BIMVFIInterpolate": "BIM-VFI Interpolate",
"BIMVFISegmentInterpolate": "BIM-VFI Segment Interpolate",
"TweenConcatVideos": "Tween Concat Videos",
"LoadEMAVFIModel": "Load EMA-VFI Model",
"EMAVFIInterpolate": "EMA-VFI Interpolate",
"EMAVFISegmentInterpolate": "EMA-VFI Segment Interpolate",
"LoadSGMVFIModel": "Load SGM-VFI Model",
"SGMVFIInterpolate": "SGM-VFI Interpolate",
"SGMVFISegmentInterpolate": "SGM-VFI Segment Interpolate",
"LoadGIMMVFIModel": "Load GIMM-VFI Model",
"GIMMVFIInterpolate": "GIMM-VFI Interpolate",
"GIMMVFISegmentInterpolate": "GIMM-VFI Segment Interpolate",
"VFIOptimizer": "VFI Optimizer",
}