Instructions to use mhnakif/comfy2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use mhnakif/comfy2 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("mhnakif/comfy2", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
| { | |
| "id": "472e377a-dd4a-4866-9b09-ebda60fd408f", | |
| "revision": 0, | |
| "last_node_id": 47, | |
| "last_link_id": 76, | |
| "nodes": [ | |
| { | |
| "id": 28, | |
| "type": "VHS_VideoInfoSource", | |
| "pos": [ | |
| 2360, | |
| 1220 | |
| ], | |
| "size": [ | |
| 270, | |
| 106 | |
| ], | |
| "flags": { | |
| "collapsed": true | |
| }, | |
| "order": 3, | |
| "mode": 0, | |
| "inputs": [ | |
| { | |
| "name": "video_info", | |
| "type": "VHS_VIDEOINFO", | |
| "link": 36 | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "name": "fps🟨", | |
| "type": "FLOAT", | |
| "links": [ | |
| 56, | |
| 57 | |
| ] | |
| }, | |
| { | |
| "name": "frame_count🟨", | |
| "type": "INT", | |
| "links": null | |
| }, | |
| { | |
| "name": "duration🟨", | |
| "type": "FLOAT", | |
| "links": null | |
| }, | |
| { | |
| "name": "width🟨", | |
| "type": "INT", | |
| "links": null | |
| }, | |
| { | |
| "name": "height🟨", | |
| "type": "INT", | |
| "links": null | |
| } | |
| ], | |
| "properties": { | |
| "enableTabs": false, | |
| "tabWidth": 65, | |
| "tabXOffset": 10, | |
| "hasSecondTab": false, | |
| "secondTabText": "Send Back", | |
| "secondTabOffset": 80, | |
| "secondTabWidth": 65, | |
| "cnr_id": "comfyui-videohelpersuite", | |
| "ver": "8550981384301e9bc5bfea83e5c2c75258102593", | |
| "Node name for S&R": "VHS_VideoInfoSource", | |
| "ue_properties": { | |
| "widget_ue_connectable": {}, | |
| "input_ue_unconnectable": {}, | |
| "version": "7.4" | |
| } | |
| }, | |
| "widgets_values": {} | |
| }, | |
| { | |
| "id": 31, | |
| "type": "VHS_LoadVideo", | |
| "pos": [ | |
| 950, | |
| 1160 | |
| ], | |
| "size": [ | |
| 850, | |
| 1559.3488372093022 | |
| ], | |
| "flags": {}, | |
| "order": 0, | |
| "mode": 0, | |
| "inputs": [ | |
| { | |
| "name": "meta_batch", | |
| "shape": 7, | |
| "type": "VHS_BatchManager", | |
| "link": null | |
| }, | |
| { | |
| "name": "vae", | |
| "shape": 7, | |
| "type": "VAE", | |
| "link": null | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "name": "IMAGE", | |
| "type": "IMAGE", | |
| "links": [ | |
| 72, | |
| 73 | |
| ] | |
| }, | |
| { | |
| "name": "frame_count", | |
| "type": "INT", | |
| "links": [] | |
| }, | |
| { | |
| "name": "audio", | |
| "type": "AUDIO", | |
| "links": [ | |
| 74, | |
| 75 | |
| ] | |
| }, | |
| { | |
| "name": "video_info", | |
| "type": "VHS_VIDEOINFO", | |
| "links": [ | |
| 36 | |
| ] | |
| } | |
| ], | |
| "properties": { | |
| "enableTabs": false, | |
| "tabWidth": 65, | |
| "tabXOffset": 10, | |
| "hasSecondTab": false, | |
| "secondTabText": "Send Back", | |
| "secondTabOffset": 80, | |
| "secondTabWidth": 65, | |
| "cnr_id": "comfyui-videohelpersuite", | |
| "ver": "8550981384301e9bc5bfea83e5c2c75258102593", | |
| "Node name for S&R": "VHS_LoadVideo", | |
| "ue_properties": { | |
| "widget_ue_connectable": {}, | |
| "input_ue_unconnectable": {}, | |
| "version": "7.4" | |
| } | |
| }, | |
| "widgets_values": { | |
| "video": "107289363 (1).mp4", | |
| "force_rate": 0, | |
| "custom_width": 0, | |
| "custom_height": 0, | |
| "frame_load_cap": 0, | |
| "skip_first_frames": 0, | |
| "select_every_nth": 1, | |
| "format": "AnimateDiff", | |
| "choose video to upload": "image", | |
| "videopreview": { | |
| "hidden": false, | |
| "paused": false, | |
| "params": { | |
| "filename": "107289363 (1).mp4", | |
| "type": "input", | |
| "format": "video/mp4", | |
| "force_rate": 0, | |
| "custom_width": 0, | |
| "custom_height": 0, | |
| "frame_load_cap": 0, | |
| "skip_first_frames": 0, | |
| "select_every_nth": 1 | |
| } | |
| } | |
| } | |
| }, | |
| { | |
| "id": 33, | |
| "type": "AILab_FlashVSR_Advanced", | |
| "pos": [ | |
| 2927.5, | |
| 1160 | |
| ], | |
| "size": [ | |
| 270, | |
| 438 | |
| ], | |
| "flags": {}, | |
| "order": 2, | |
| "mode": 0, | |
| "inputs": [ | |
| { | |
| "name": "frames", | |
| "type": "IMAGE", | |
| "link": 73 | |
| }, | |
| { | |
| "name": "audio", | |
| "shape": 7, | |
| "type": "AUDIO", | |
| "link": 75 | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "name": "frames", | |
| "type": "IMAGE", | |
| "links": [ | |
| 52 | |
| ] | |
| }, | |
| { | |
| "name": "audio", | |
| "type": "AUDIO", | |
| "links": [ | |
| 53 | |
| ] | |
| } | |
| ], | |
| "properties": { | |
| "enableTabs": false, | |
| "tabWidth": 65, | |
| "tabXOffset": 10, | |
| "hasSecondTab": false, | |
| "secondTabText": "Send Back", | |
| "secondTabOffset": 80, | |
| "secondTabWidth": 65, | |
| "ue_properties": { | |
| "widget_ue_connectable": {}, | |
| "input_ue_unconnectable": {} | |
| }, | |
| "cnr_id": "ComfyUI-FlashVSR", | |
| "ver": "98f2769d74e74835df307b93e6b38268e173594f", | |
| "Node name for S&R": "AILab_FlashVSR_Advanced" | |
| }, | |
| "widgets_values": [ | |
| "Full (Best Quality)", | |
| 2, | |
| true, | |
| 256, | |
| 24, | |
| 2, | |
| 2, | |
| 11, | |
| true, | |
| true, | |
| false, | |
| "enable", | |
| "auto", | |
| "bf16", | |
| 100, | |
| "fixed" | |
| ] | |
| }, | |
| { | |
| "id": 39, | |
| "type": "VHS_VideoCombine", | |
| "pos": [ | |
| 3200, | |
| 1160 | |
| ], | |
| "size": [ | |
| 850, | |
| 1555.2727272727273 | |
| ], | |
| "flags": {}, | |
| "order": 5, | |
| "mode": 0, | |
| "inputs": [ | |
| { | |
| "name": "images", | |
| "type": "IMAGE", | |
| "link": 52 | |
| }, | |
| { | |
| "name": "audio", | |
| "shape": 7, | |
| "type": "AUDIO", | |
| "link": 53 | |
| }, | |
| { | |
| "name": "meta_batch", | |
| "shape": 7, | |
| "type": "VHS_BatchManager", | |
| "link": null | |
| }, | |
| { | |
| "name": "vae", | |
| "shape": 7, | |
| "type": "VAE", | |
| "link": null | |
| }, | |
| { | |
| "name": "frame_rate", | |
| "type": "FLOAT", | |
| "widget": { | |
| "name": "frame_rate" | |
| }, | |
| "link": 57 | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "name": "Filenames", | |
| "type": "VHS_FILENAMES", | |
| "links": null | |
| } | |
| ], | |
| "properties": { | |
| "enableTabs": false, | |
| "tabWidth": 65, | |
| "tabXOffset": 10, | |
| "hasSecondTab": false, | |
| "secondTabText": "Send Back", | |
| "secondTabOffset": 80, | |
| "secondTabWidth": 65, | |
| "ue_properties": { | |
| "widget_ue_connectable": {}, | |
| "input_ue_unconnectable": {}, | |
| "version": "7.4" | |
| }, | |
| "cnr_id": "comfyui-videohelpersuite", | |
| "ver": "8550981384301e9bc5bfea83e5c2c75258102593", | |
| "Node name for S&R": "VHS_VideoCombine" | |
| }, | |
| "widgets_values": { | |
| "frame_rate": 8, | |
| "loop_count": 0, | |
| "filename_prefix": "FlashVSR", | |
| "format": "video/h264-mp4", | |
| "pix_fmt": "yuv420p", | |
| "crf": 19, | |
| "save_metadata": false, | |
| "trim_to_audio": false, | |
| "pingpong": false, | |
| "save_output": false, | |
| "videopreview": { | |
| "hidden": false, | |
| "paused": false, | |
| "params": { | |
| "filename": "FlashVSR_00013.mp4", | |
| "subfolder": "", | |
| "type": "temp", | |
| "format": "video/h264-mp4", | |
| "frame_rate": 32, | |
| "workflow": "FlashVSR_00013.png", | |
| "fullpath": "C:\\AI\\ComfyUI\\ComfyUI\\temp\\FlashVSR_00013.mp4" | |
| } | |
| } | |
| } | |
| }, | |
| { | |
| "id": 40, | |
| "type": "VHS_VideoCombine", | |
| "pos": [ | |
| 2075, | |
| 1160 | |
| ], | |
| "size": [ | |
| 850, | |
| 1555.2727272727273 | |
| ], | |
| "flags": { | |
| "collapsed": false | |
| }, | |
| "order": 4, | |
| "mode": 0, | |
| "inputs": [ | |
| { | |
| "name": "images", | |
| "type": "IMAGE", | |
| "link": 64 | |
| }, | |
| { | |
| "name": "audio", | |
| "shape": 7, | |
| "type": "AUDIO", | |
| "link": 65 | |
| }, | |
| { | |
| "name": "meta_batch", | |
| "shape": 7, | |
| "type": "VHS_BatchManager", | |
| "link": null | |
| }, | |
| { | |
| "name": "vae", | |
| "shape": 7, | |
| "type": "VAE", | |
| "link": null | |
| }, | |
| { | |
| "name": "frame_rate", | |
| "type": "FLOAT", | |
| "widget": { | |
| "name": "frame_rate" | |
| }, | |
| "link": 56 | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "name": "Filenames", | |
| "type": "VHS_FILENAMES", | |
| "links": null | |
| } | |
| ], | |
| "properties": { | |
| "enableTabs": false, | |
| "tabWidth": 65, | |
| "tabXOffset": 10, | |
| "hasSecondTab": false, | |
| "secondTabText": "Send Back", | |
| "secondTabOffset": 80, | |
| "secondTabWidth": 65, | |
| "ue_properties": { | |
| "widget_ue_connectable": {}, | |
| "input_ue_unconnectable": {} | |
| }, | |
| "cnr_id": "comfyui-videohelpersuite", | |
| "ver": "8550981384301e9bc5bfea83e5c2c75258102593", | |
| "Node name for S&R": "VHS_VideoCombine" | |
| }, | |
| "widgets_values": { | |
| "frame_rate": 8, | |
| "loop_count": 0, | |
| "filename_prefix": "FlashVSR", | |
| "format": "video/h264-mp4", | |
| "pix_fmt": "yuv420p", | |
| "crf": 19, | |
| "save_metadata": false, | |
| "trim_to_audio": false, | |
| "pingpong": false, | |
| "save_output": false, | |
| "videopreview": { | |
| "hidden": false, | |
| "paused": false, | |
| "params": { | |
| "filename": "FlashVSR_00007.mp4", | |
| "subfolder": "", | |
| "type": "output", | |
| "format": "video/h264-mp4", | |
| "frame_rate": 32, | |
| "workflow": "FlashVSR_00007.png", | |
| "fullpath": "O:\\Outputs\\ComfyUI\\FlashVSR_00007.mp4" | |
| } | |
| } | |
| } | |
| }, | |
| { | |
| "id": 45, | |
| "type": "AILab_FlashVSR", | |
| "pos": [ | |
| 1802.5, | |
| 1160 | |
| ], | |
| "size": [ | |
| 270, | |
| 174 | |
| ], | |
| "flags": {}, | |
| "order": 1, | |
| "mode": 0, | |
| "inputs": [ | |
| { | |
| "name": "frames", | |
| "type": "IMAGE", | |
| "link": 72 | |
| }, | |
| { | |
| "name": "audio", | |
| "shape": 7, | |
| "type": "AUDIO", | |
| "link": 74 | |
| } | |
| ], | |
| "outputs": [ | |
| { | |
| "name": "FRAMES", | |
| "type": "IMAGE", | |
| "links": [ | |
| 64 | |
| ] | |
| }, | |
| { | |
| "name": "AUDIO", | |
| "type": "AUDIO", | |
| "links": [ | |
| 65 | |
| ] | |
| } | |
| ], | |
| "properties": { | |
| "enableTabs": false, | |
| "tabWidth": 65, | |
| "tabXOffset": 10, | |
| "hasSecondTab": false, | |
| "secondTabText": "Send Back", | |
| "secondTabOffset": 80, | |
| "secondTabWidth": 65, | |
| "ue_properties": { | |
| "widget_ue_connectable": {}, | |
| "input_ue_unconnectable": {} | |
| }, | |
| "cnr_id": "ComfyUI-FlashVSR", | |
| "ver": "98f2769d74e74835df307b93e6b38268e173594f", | |
| "Node name for S&R": "AILab_FlashVSR" | |
| }, | |
| "widgets_values": [ | |
| "Fast (2x Speed)", | |
| 4, | |
| false, | |
| 100, | |
| "fixed" | |
| ] | |
| } | |
| ], | |
| "links": [ | |
| [ | |
| 36, | |
| 31, | |
| 3, | |
| 28, | |
| 0, | |
| "VHS_VIDEOINFO" | |
| ], | |
| [ | |
| 52, | |
| 33, | |
| 0, | |
| 39, | |
| 0, | |
| "IMAGE" | |
| ], | |
| [ | |
| 53, | |
| 33, | |
| 1, | |
| 39, | |
| 1, | |
| "AUDIO" | |
| ], | |
| [ | |
| 56, | |
| 28, | |
| 0, | |
| 40, | |
| 4, | |
| "FLOAT" | |
| ], | |
| [ | |
| 57, | |
| 28, | |
| 0, | |
| 39, | |
| 4, | |
| "FLOAT" | |
| ], | |
| [ | |
| 64, | |
| 45, | |
| 0, | |
| 40, | |
| 0, | |
| "IMAGE" | |
| ], | |
| [ | |
| 65, | |
| 45, | |
| 1, | |
| 40, | |
| 1, | |
| "AUDIO" | |
| ], | |
| [ | |
| 72, | |
| 31, | |
| 0, | |
| 45, | |
| 0, | |
| "IMAGE" | |
| ], | |
| [ | |
| 73, | |
| 31, | |
| 0, | |
| 33, | |
| 0, | |
| "IMAGE" | |
| ], | |
| [ | |
| 74, | |
| 31, | |
| 2, | |
| 45, | |
| 1, | |
| "AUDIO" | |
| ], | |
| [ | |
| 75, | |
| 31, | |
| 2, | |
| 33, | |
| 1, | |
| "AUDIO" | |
| ] | |
| ], | |
| "groups": [], | |
| "config": {}, | |
| "extra": { | |
| "ue_links": [], | |
| "links_added_by_ue": [], | |
| "ds": { | |
| "scale": 0.9090909090909095, | |
| "offset": [ | |
| -290.89177354607716, | |
| -1011.3103857698936 | |
| ] | |
| }, | |
| "frontendVersion": "1.28.7", | |
| "VHS_latentpreview": false, | |
| "VHS_latentpreviewrate": 0, | |
| "VHS_MetadataImage": true, | |
| "VHS_KeepIntermediate": true | |
| }, | |
| "version": 0.4 | |
| } |