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

Add symmetric quantization with no clipping error in the tensor subclass based API #845

Merged
merged 1 commit into from
Sep 9, 2024

Conversation

iseeyuan
Copy link
Contributor

@iseeyuan iseeyuan commented Sep 9, 2024

Follow up with #805 , add the same option to the new tensor subclass API.

Copy link

pytorch-bot bot commented Sep 9, 2024

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/ao/845

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit d2d2af4 with merge base 1b317f9 (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Sep 9, 2024
@iseeyuan iseeyuan force-pushed the newapi branch 2 times, most recently from 9b1120b to 3b9324e Compare September 9, 2024 22:08
@iseeyuan iseeyuan merged commit c842d50 into main Sep 9, 2024
17 checks passed
@@ -473,14 +473,13 @@ def _int8_asymm_per_token_quant(x: torch.Tensor) -> torch.Tensor:
target_dtype = torch.int8
return to_affine_quantized_intx(x, mapping_type, _get_per_token_block_size(x), target_dtype)

def apply_int8_dynamic_activation_int4_weight_quant(weight, group_size=32):
def apply_int8_dynamic_activation_int4_weight_quant(weight, group_size=32, mapping_type=MappingType.SYMMETRIC):
Copy link
Contributor

Choose a reason for hiding this comment

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

might be better to clarify this is weight_mapping_type I feel

@jerryzh168
Copy link
Contributor

@iseeyuan although the merging is not blocked, please still wait for an approval before merging next time :)

yanbing-j pushed a commit to yanbing-j/ao that referenced this pull request Dec 9, 2024
* Initial move of browser GUI related files

* Fix css reference issue

* Remove moved file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants