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

update_onediff_comfy_nodes_README #477

Merged
merged 4 commits into from
Dec 29, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 6 additions & 42 deletions onediff_comfy_nodes/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,16 @@
- [Installation Guide](#installation-guide)
- [Basical Nodes Usage](#basical-nodes-usage)
- [Model Acceleration](#model-acceleration)
- [Model Speedup](#model-speedup)
- [Model Graph Saver](#model-graph-saver)
- [Model Graph Loader](#model-graph-loader)
- [Load Checkpoint - OneDiff](#load-checkpoint---onediff)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

更新下 comfy 社区版的性能数据吧

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

已更新

- [Quantization](#quantization)
- [Image Distinction Scanner](#image-distinction-scanner)
- [Examples](#onediff-community-examples)
- [OneDiff Community Examples](#onediff-community-examples)
- [LoRA](#lora)
- [ControlNet](#controlnet)
- [SVD](#svd)
- [DeepCache](#deepcache)



## Performance of Community Edition

Updated on DEC 7, 2023. Device: RTX 3090
Expand Down Expand Up @@ -80,29 +77,17 @@ If you need Enterprise Level Support for your system or business, please refer t

### Model Acceleration

#### Model Speedup

The "Model Speedup" node takes a model as input and outputs an optimized model.
#### Load Checkpoint - OneDiff

If the `static_mode` is `enabled` (which is the default), it will take some time to compile before the first inference.
The "Load Checkpoint - OneDiff" node is optimized for OneDiff.

If `static_model` is `disabled`, there is no need for additional compilation time before the first inference, but the inference speed will be slower compared to `enabled`, albeit slightly.
It can be used to load checkpoints and accelerate the model.

![](workflows/model-speedup.png)

#### Model Graph Saver

The optimized model from the "Model Speedup" node can be saved to "graph" by the "Model Graph Saver" node, allowing it to be used in other scenarios without the need for recompilation.

![](workflows/model-graph-saver.png)

You can set different file name prefixes for different types of models.

#### Model Graph Loader
The "Load Checkpoint - OneDiff" node set `vae_speedup` : `enable` to enable VAE acceleration.

The "Model Graph Loader" node is used to load graph files from the disk, thus saving the time required for the initial compilation.

![](workflows/model-graph-loader.png)

### Quantization

Expand All @@ -114,27 +99,6 @@ The "UNet Loader Int8" node is used to load quantized models. Quantized models n

The compilation result of the quantized model can also be saved as a graph and loaded when needed.


![quantized model saver](workflows/int8-graph-saver.png)

![quantized model loader](workflows/int8-graph-loader.png)


### VAE Acceleration

The VAE nodes used for accelerating, saving, and loading VAE graphs operate in a manner very similar to the usage of Model nodes.

Omitting specific details here, the following workflow can be loaded and tested.

**VAE Speedup and Graph Saver**

![](workflows/vae-graph-saver.png)

**VAE Speedup and Graph Loader**

![](workflows/vae-graph-loader.png)


### Image Distinction Scanner

The "Image Distinction Scanner" node is used to compare the differences between two images and visualize the resulting variances.
Expand Down
Binary file modified onediff_comfy_nodes/workflows/model-speedup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading