diffusers icon indicating copy to clipboard operation
diffusers copied to clipboard

Cannot import name 'DPMSolverMultistepScheduler' from 'diffusers'

Open WASasquatch opened this issue 2 years ago • 9 comments

Describe the bug

I'm trying to install diffusers on my new Windows 11 computer, and it's failing on DPMSolverMultistepScheduler, which I thought was merged?

Reproduction

pip install diffusers[torch] transformers accelerate ftfy

and then try

from diffusers import DPMSolverMultistepScheduler

Logs

from diffusers import (
ImportError: cannot import name 'DPMSolverMultistepScheduler' from 'diffusers' (C:\SKYNET-MASTER\WAS\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\diffusers\__init__.py)

System Info

  • diffusers version: 0.7.2
  • Platform: Windows-10-10.0.22000-SP0
  • Python version: 3.9.13
  • PyTorch version (GPU?): 1.13.0+cpu (False)
  • Huggingface_hub version: 0.10.1
  • Transformers version: 4.24.0
  • Using GPU in script?: yes
  • Using distributed or parallel set-up in script?: no

Extra Notes

On colab, this isn't a issue, it imports fine, and runs fine. So unsure what the issue is.

WASasquatch avatar Nov 11 '22 22:11 WASasquatch

DPMSolverMultistepScheduler wasn't merged into the 0.7.2 patch. The available schedulers in 0.7.x are here DPMSolverMultistepScheduler is included in the current 0.8.0dev0 files

averad avatar Nov 11 '22 23:11 averad

DPMSolverMultistepScheduler wasn't merged into the 0.7.2 patch. The available schedulers in 0.7.x are here DPMSolverMultistepScheduler is included in the current 0.8.0dev0 files

Oh that's so strange. On colab, I just pip installed diffusers[torch] and been using it. Is there some sort of auto package selection?

WASasquatch avatar Nov 12 '22 03:11 WASasquatch

DPMSolver is currently only available on "main" I'm afraid

patrickvonplaten avatar Nov 16 '22 21:11 patrickvonplaten

@WASasquatch use pip install git+https://github.com/huggingface/diffusers.git

averad avatar Nov 17 '22 20:11 averad

I've tried this, uninstalling, and even pip install --upgrade git+ https://github.com/huggingface/diffusers.git to be sure. Something must not be being removed right with pip on windows or something. I even forked the repo, from main, and replaced the files. 💁

On Thu, Nov 17, 2022 at 12:15 PM averad @.***> wrote:

@WASasquatch https://github.com/WASasquatch use pip install git+ https://github.com/huggingface/diffusers.git

— Reply to this email directly, view it on GitHub https://github.com/huggingface/diffusers/issues/1260#issuecomment-1319150048, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIZEZJYZWPA3AFAFZ3GEQDWI2G6ZANCNFSM6AAAAAAR5724K4 . You are receiving this because you were mentioned.Message ID: @.***>

-- Sincerely, *Jordan S. C. Thompson *

WASasquatch avatar Nov 17 '22 21:11 WASasquatch

That is really strange, pulling the diffusers repo using git should result in the scheduler being available. Did you verify the diffusers version is showing as 0.8.0dev0 using diffusers-cli env

Example:

  • diffusers version: 0.8.0.dev0
  • Platform: Windows-10-10.0.22621-SP0
  • Python version: 3.10.8
  • PyTorch version (GPU?): 1.13.0+cpu (False)
  • Huggingface_hub version: 0.10.1
  • Transformers version: 4.24.0
  • Using GPU in script?:
  • Using distributed or parallel set-up in script?:

averad avatar Nov 17 '22 22:11 averad

- `diffusers` version: 0.8.0.dev0
- Platform: Windows-10-10.0.22621-SP0
- Python version: 3.9.13
- PyTorch version (GPU?): 1.13.0+cu117 (True)
- Huggingface_hub version: 0.10.1
- Transformers version: 4.24.0
- Using GPU in script?: Yes
- Using distributed or parallel set-up in script?: No

WASasquatch avatar Nov 19 '22 05:11 WASasquatch

This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the contributing guidelines are likely to be ignored.

github-actions[bot] avatar Dec 13 '22 15:12 github-actions[bot]

I think one needs to simple update the diffusers version here:

pip install --upgrade diffusers

patrickvonplaten avatar Dec 19 '22 11:12 patrickvonplaten

This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the contributing guidelines are likely to be ignored.

github-actions[bot] avatar Jan 12 '23 15:01 github-actions[bot]