Added quantization implementation.