onediff icon indicating copy to clipboard operation
onediff copied to clipboard

save_pipe and load_pipe not work

Open forestlet opened this issue 5 months ago • 8 comments

Describe the bug

I use OneDiffX (for HF diffusers) and Compile, save and load pipeline. after I run save_pipe example, there is nothing in cached_pipe

Your environment

Ubuntu LTS

OneDiff git commit id

500459f

OneFlow version info

libibverbs not available, ibv_fork_init skipped path: ['/home/ubuntu/.local/lib/python3.10/site-packages/oneflow'] version: 0.9.1.dev20240307+cu121 git_commit: 88ece9e cmake_build_type: Release rdma: True mlir: True enterprise: False

How To Reproduce

Steps to reproduce the behavior(code or script):

from diffusers import StableDiffusionXLPipeline
from onediffx import compile_pipe, save_pipe
pipe = StableDiffusionXLPipeline.from_pretrained(
    "stabilityai/stable-diffusion-xl-base-1.0",
    torch_dtype=torch.float16,
    variant="fp16",
    use_safetensors=True
)
pipe.to("cuda")

pipe = compile_pipe(pipe)

save_pipe(pipe, dir="cached_pipe")

Additional context

Each time it takes too long to compile, however, the save_pipe func seems doesn't work.

forestlet avatar Mar 09 '24 09:03 forestlet