Unverified Commit 57e50f8d authored by Muyang Li's avatar Muyang Li Committed by GitHub
Browse files

style: upgrade the linter (#339)

* style: reformated codes

* style: reformated codes
parent b737368d
......@@ -35,7 +35,7 @@ To test visual output correctness, you can:
lpips = compute_lpips(dir1, dir2)
```
Here, `dir1` should point to the directory containing the reference images, and `dir2` should contain the images generated by your method.
Here, `dir1` should point to the directory containing the reference images, and `dir2` should contain the images generated by your method.
### Setting the LPIPS Threshold
......@@ -43,4 +43,4 @@ To pass the test, the LPIPS score must be below a predefined threshold—typical
## Acknowledgments
This contribution guide is adapted from [SGLang](https://github.com/sgl-project/sglang/tree/main/test). We thank them for the inspiration.
\ No newline at end of file
This contribution guide is adapted from [SGLang](https://github.com/sgl-project/sglang/tree/main/test). We thank them for the inspiration.
......@@ -3,7 +3,6 @@ import random
import datasets
import yaml
from huggingface_hub import snapshot_download
from nunchaku.utils import fetch_or_download
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......@@ -9,7 +10,7 @@ from .utils import run_test
"use_double_fb_cache,residual_diff_threshold_multi,residual_diff_threshold_single,height,width,num_inference_steps,lora_name,lora_strength,expected_lpips",
[
(True, 0.09, 0.12, 1024, 1024, 30, None, 1, 0.24 if get_precision() == "int4" else 0.165),
(True, 0.09, 0.12, 1024, 1024, 50, None, 1, 0.24 if get_precision() == "int4" else 0.144),
(True, 0.09, 0.12, 1024, 1024, 50, None, 1, 0.24 if get_precision() == "int4" else 0.161),
],
)
def test_flux_dev_double_fb_cache(
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
......@@ -8,6 +8,7 @@ from diffusers.pipelines.flux.pipeline_flux import FluxPipeline
from nunchaku import NunchakuFluxTransformer2dModel
from nunchaku.caching.teacache import TeaCache
from nunchaku.utils import get_precision, is_turing
from .utils import already_generate, compute_lpips, offload_pipeline
......
......@@ -2,6 +2,7 @@ import pytest
import torch
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
......@@ -2,6 +2,7 @@
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
import pytest
from nunchaku.utils import get_precision, is_turing
from .utils import run_test
......
......@@ -14,6 +14,7 @@ import nunchaku
from nunchaku import NunchakuFluxTransformer2dModel, NunchakuT5EncoderModel
from nunchaku.caching.diffusers_adapters import apply_cache_on_pipe
from nunchaku.lora.flux.compose import compose_lora
from ..data import get_dataset
from ..utils import already_generate, compute_lpips, hash_str_to_int
......
......@@ -9,4 +9,4 @@ git+https://github.com/asomoza/image_gen_aux.git
insightface
opencv-python
facexlib
onnxruntime
\ No newline at end of file
onnxruntime
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment