feat: add act_fn
param to OutValueFunctionBlock
by SauravMaheshkar · Pull Request #3994 · huggingface/diffusers (original) (raw)
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 andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation8 Commits27 Checks0 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
What does this PR do?
(Hopefully) fixes #1287
Before submitting
- This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- Did you read the contributor guideline?
- Did you read our philosophy doc (important for complex PRs)?
- Was this discussed/approved via a Github issue or the forum? Please add a link to it if that's the case.
- Did you make sure to update the documentation with your changes? Here are the
documentation guidelines, and
here are tips on formatting docstrings. - Did you write any new necessary tests?
Who can review?
Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.
Request for Review: @natolambert
The documentation is not available anymore as the PR was closed or merged.
Let's add some folks from the Diffusers team, I'm not actively working on this anymore @patrickvonplaten
I don't fully understand what this fixes. Could you maybe elaborate here @SauravMaheshkar ? :-)
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
I don't fully understand what this fixes. Could you maybe elaborate here @SauravMaheshkar ? :-)
Hey @patrickvonplaten thanks for getting back. This doesn't fix an issue but I rather wanted to raise the discussion about how to fix #1287. A very naive fix could be to simply change the activation to swish
in prepare_init_args_and_inputs_for_common
( in tests/models/test_models_unet_1d.py
) to solve the problem (and updating the OutValueFunctionBlock
to not have mish
)?
But if not what would you suggest is a way to fix it ? I'm afraid I can't understand #1287 (comment)
TBH, I also don't fully understand the discussion of #1287 - I'm ok with merging this PR as is though if it helps for your use case :-)
Well this PR changes the activation function to be swish
instead of mish
so we can drop the decorators (@unittest.skipIf(torch_device == "mps", "mish op not supported in MPS")
). @patrickvonplaten I made changes in this PR. LMK if they make sense.
orpatashnik pushed a commit to orpatashnik/diffusers that referenced this pull request
feat: add act_fn param to OutValueFunctionBlock
feat: update unet1d tests to not use mish
feat: add
mish
as the default activation function
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
- feat: drop mish tests from unet1d
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
orpatashnik pushed a commit to orpatashnik/diffusers that referenced this pull request
feat: add act_fn param to OutValueFunctionBlock
feat: update unet1d tests to not use mish
feat: add
mish
as the default activation function
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
- feat: drop mish tests from unet1d
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
orpatashnik pushed a commit to orpatashnik/diffusers that referenced this pull request
feat: add act_fn param to OutValueFunctionBlock
feat: update unet1d tests to not use mish
feat: add
mish
as the default activation function
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
- feat: drop mish tests from unet1d
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
yoonseokjin pushed a commit to yoonseokjin/diffusers that referenced this pull request
feat: add act_fn param to OutValueFunctionBlock
feat: update unet1d tests to not use mish
feat: add
mish
as the default activation function
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
- feat: drop mish tests from unet1d
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
AmericanPresidentJimmyCarter pushed a commit to AmericanPresidentJimmyCarter/diffusers that referenced this pull request
feat: add act_fn param to OutValueFunctionBlock
feat: update unet1d tests to not use mish
feat: add
mish
as the default activation function
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com
- feat: drop mish tests from unet1d
Co-authored-by: Patrick von Platen patrick.v.platen@gmail.com