FP32 Tensor to Int8 Quantization

FP32 Tensor to Int8 Quantization

Implement quantize_fp32_to_int8(x, scale).

  • x is an FP32 tensor of arbitrary shape.
  • scale is a positive floating-point value.
  • For every element, comput...

Example

Unlock to view complete problem details

and practice with sample input/output

Was this article helpful?

View Test Cases & Run Code requires membership

Standard Input
Execution Result: