Skip to content

Conversation

@mshr-h
Copy link
Contributor

@mshr-h mshr-h commented Jun 12, 2024

#17068

This is only for the fx frontend. But ONNX has the same HardSwish operator. I am thinking to add something like relax.nn.hardswish operator and call it from fx/onnx frontend after this PR is merged.

cc @yongwww @tqchen

@mshr-h mshr-h marked this pull request as ready for review June 12, 2024 13:24
@github-actions github-actions bot requested review from tqchen and yongwww June 12, 2024 14:15
Copy link
Member

@yongwww yongwww left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@yongwww
Copy link
Member

yongwww commented Jun 12, 2024

I am not sure if we need to introduce a new operator Hardswish to relax, looks we can compose it with several existing ops like add, and those ops are able to be fused by FuseOps pass, that means we won't lose perf even we compose it with several existing ops.

cc: @tqchen @vinx13 @MasterJH5574

@vinx13 vinx13 merged commit cc7eb2f into apache:main Jun 12, 2024
@mshr-h mshr-h deleted the relax-fx-hardswish branch June 13, 2024 02:29
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.

3 participants