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

[quant][eagermode] Add support for sigmoid module #45884

Closed
wants to merge 5 commits into from

Conversation

jerryzh168
Copy link
Contributor

@jerryzh168 jerryzh168 commented Oct 6, 2020

Stack from ghstack:

Summary:

Test Plan:
python test/test_quantization.py TestEagerModeOps.test_sigmoid

Reviewers:

Subscribers:

Tasks:

Tags:

Differential Revision: D24129115

Summary:

Test Plan:
python test/test_quantization.py TestEagerModeOps.test_sigmoid

Reviewers:

Subscribers:

Tasks:

Tags:

[ghstack-poisoned]
Summary:

Test Plan:
python test/test_quantization.py TestEagerModeOps.test_sigmoid

Reviewers:

Subscribers:

Tasks:

Tags:

Differential Revision: [D24129115](https://our.internmc.facebook.com/intern/diff/D24129115)

[ghstack-poisoned]
Summary:

Test Plan:
python test/test_quantization.py TestEagerModeOps.test_sigmoid

Reviewers:

Subscribers:

Tasks:

Tags:

Differential Revision: [D24129115](https://our.internmc.facebook.com/intern/diff/D24129115)

[ghstack-poisoned]
Summary:

Test Plan:
python test/test_quantization.py TestEagerModeOps.test_sigmoid

Reviewers:

Subscribers:

Tasks:

Tags:

Differential Revision: [D24129115](https://our.internmc.facebook.com/intern/diff/D24129115)

[ghstack-poisoned]
Summary:

Test Plan:
python test/test_quantization.py TestEagerModeOps.test_sigmoid

Reviewers:

Subscribers:

Tasks:

Tags:

Differential Revision: [D24129115](https://our.internmc.facebook.com/intern/diff/D24129115)

[ghstack-poisoned]
@jerryzh168
Copy link
Contributor Author

we'll use fixed quantization parameter for sigmoid since there are implementations that only implements sigmoid with fixed quantization parameters, e.g. qnnpack: https://github.com/pytorch/pytorch/blob/master/aten/src/ATen/native/quantized/cpu/qnnpack/src/sigmoid.c#L72, and it uses LUT as an optimization. this can't be done if we support arbitrary output_scale and output_zero_point.

@jerryzh168 jerryzh168 closed this Oct 20, 2020
@facebook-github-bot facebook-github-bot deleted the gh/jerryzh168/455/head branch November 20, 2020 15:18
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

3 participants