smhongok/inv-dpm

AttributeError: 'bool' object has no attribute '__module__'

Jason-Chi-xx opened this issue · 2 comments

when I try to run the Generation part in exact_inversion.ipynb, it yielded the following fault:
AttributeError Traceback (most recent call last)
Cell In[2], line 2
1 image_num = 96
----> 2 image, prompt, _ = generate(image_num=image_num, num_inference_steps=50, solver_order=1)
4 plt.imshow(image)
5 plt.title("\n".join(textwrap.wrap(prompt)), wrap=True)

File ~/inv-dpm/our_functions.py:67, in generate(image_num, prompt, guidance_scale, num_inference_steps, solver_order, image_length, datasets, model_id, gen_seed, pipe, init_latents)
56 if pipe is None:
57 scheduler = DPMSolverMultistepScheduler(
58 beta_end=0.012,
59 beta_schedule='scaled_linear',
(...)
65 solver_order=solver_order,
66 )
---> 67 pipe = InversableStableDiffusionPipeline.from_pretrained(
68 model_id,
69 scheduler=scheduler,
70 torch_dtype=torch.float32,
71 )
72 pipe = pipe.to(device)
74 # load dataset and prompt

File ~/miniconda3/lib/python3.11/site-packages/huggingface_hub/utils/_validators.py:118, in validate_hf_hub_args.._inner_fn(*args, **kwargs)
...
--> 571 library = not_compiled_module.module.split(".")[0]
573 # check if the module is a pipeline module
574 module_path_items = not_compiled_module.module.split(".")

AttributeError: 'bool' object has no attribute 'module'

What's wrong with it

It seems like the version of the library is different from me, I guess,

So I upload the full version of the dependencies, to 'requirements_conda.txt'.

Please check the version of that, such as huggingface_hub=0.19.4.

Thank you,
Seongmin

It seems like the version of the library is different from me, I guess,

So I upload the full version of the dependencies, to 'requirements_conda.txt'.

Please check the version of that, such as huggingface_hub=0.19.4.

Thank you, Seongmin

Thank you so much for your quick answer. The problem seems to be indeed related to the version of diffusers, as it goes wrong when I use diffusers=0.25.1. But it worked when I turn to diffusers=0.21.4. Thank you again