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

fix_ Unsupported type: <class 'type'> e=TypeError('type.__new__() #446

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

ccssu
Copy link
Contributor

@ccssu ccssu commented Dec 21, 2023

报错: Unsupported type: <class 'type'> e=TypeError('type.new()
diffusers_0.25 中 类对象中有一个 self.linear_cls ,导致 torch2oflow 无法转换
link: https://github.com/huggingface/diffusers/blob/325f6c53edf10a7b3f4804d4b38e89f95873d3c2/src/diffusers/models/attention_processor.py#L184-L187

self.dict[k] = torch2oflow(attr)

(Pdb) p attr
<class 'diffusers.models.lora.LoRACompatibleLinear'>
(Pdb) p k
'linear_cls'
(Pdb) p torch2oflow(attr)

@ccssu ccssu changed the title Unsupported type: <class 'type'> e=TypeError('type.__new__() fix_ Unsupported type: <class 'type'> e=TypeError('type.__new__() Dec 21, 2023
@ccssu ccssu requested a review from strint December 21, 2023 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant