Skip to content

Commit

Permalink
add definition for affine
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew committed Jun 8, 2021
1 parent 734a0d8 commit c150e4f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion python/tvm/relay/op/op.py
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,8 @@ def register_fake_quantization_to_integer(op_name, func=None, level=10):
"""Register quantize function for an op
Given an op and Affine Types on it's inputs, this function should return the op
in affine space/integer operators and the new type of the output
in affine space/integer operators and the new type of the output, where affine
denotes the transformation x_real = (x_affine - zero_point) * scale
Parameters
----------
Expand Down
3 changes: 2 additions & 1 deletion src/relay/transforms/fake_quantization_to_integer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@
*
* The second pass is an ExprVisitor that recursively searches for subgraphs leading to the
* quantize for subtraphs bounded by dequantize operations. This pass extracts the affine
* types of the inputs for later processing
* types of the inputs for later processing, where affine denotes the transformation
* x_real = (x_affine - zero_point) * scale
*
* The third pass is an ExprMutator that recursively rewrites the subgraphs using packed funcs
* registered with the FTVMFakeQuantizationToInteger attribute. These packed funcs rewrite
Expand Down

0 comments on commit c150e4f

Please sign in to comment.