{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/quantizing-deep-convolutional-networks-for","title":"Quantizing deep convolutional networks for efficient inference: A whitepaper","arxiv_id":"1806.08342","date":"2018-06-21","proceeding":null,"authors":["Raghuraman Krishnamoorthi"],"abstract":"We present an overview of techniques for quantizing convolutional neural\nnetworks for inference with integer weights and activations. Per-channel\nquantization of weights and per-layer quantization of activations to 8-bits of\nprecision post-training produces classification accuracies within 2% of\nfloating point networks for a wide variety of CNN architectures. Model sizes\ncan be reduced by a factor of 4 by quantizing weights to 8-bits, even when\n8-bit arithmetic is not supported. This can be achieved with simple, post\ntraining quantization of weights.We benchmark latencies of quantized networks\non CPUs and DSPs and observe a speedup of 2x-3x for quantized implementations\ncompared to floating point on CPUs. Speedups of up to 10x are observed on\nspecialized processors with fixed point SIMD capabilities, like the Qualcomm\nQDSPs with HVX.\n  Quantization-aware training can provide further improvements, reducing the\ngap to floating point to 1% at 8-bit precision. Quantization-aware training\nalso allows for reducing the precision of weights to four bits with accuracy\nlosses ranging from 2% to 10%, with higher accuracy drop for smaller\nnetworks.We introduce tools in TensorFlow and TensorFlowLite for quantizing\nconvolutional networks and review best practices for quantization-aware\ntraining to obtain high accuracy with quantized weights and activations. We\nrecommend that per-channel quantization of weights and per-layer quantization\nof activations be the preferred quantization scheme for hardware acceleration\nand kernel optimization. We also propose that future processors and hardware\naccelerators for optimized inference support precisions of 4, 8 and 16 bits.","url_abs":"http://arxiv.org/abs/1806.08342v1","url_pdf":"http://arxiv.org/pdf/1806.08342v1.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"quantizing-deep-convolutional-networks-for","repo_url":"https://github.com/KwangHoonAn/Quantizations","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}},{"paper_slug":"quantizing-deep-convolutional-networks-for","repo_url":"https://github.com/lz20061213/darknet-ameliorate","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"none","reach":{"status":"ok"}},{"paper_slug":"quantizing-deep-convolutional-networks-for","repo_url":"https://github.com/shiyongming/calib-dataset-eval","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"quantization","task_name":"Quantization"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1806.08342","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1806.08342"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/shiyongming/calib-dataset-eval","reach":{"status":"ok","spdx":"Apache-2.0"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/lz20061213/darknet-ameliorate","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/KwangHoonAn/Quantizations","reach":{"status":"ok"}}],"summary":{"unverified":4},"by_repo_kind":{"listed":{"samples":4,"ran":0,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"04a936b0f51bf9e0","entry":"generate_wh_xyminmax_list","repo":"shiyongming/calib-dataset-eval","repo_kind":"listed","path":"datasetapi/voc_dataset/voc_data_processing.py","file_url":"https://github.com/shiyongming/calib-dataset-eval/blob/HEAD/datasetapi/voc_dataset/voc_data_processing.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"04a936b0f51bf9e0"}},{"code_sha256_prefix":"2bea700a40208e46","entry":"generate_xml_and_image_list","repo":"shiyongming/calib-dataset-eval","repo_kind":"listed","path":"datasetapi/voc_dataset/voc_data_processing.py","file_url":"https://github.com/shiyongming/calib-dataset-eval/blob/HEAD/datasetapi/voc_dataset/voc_data_processing.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"2bea700a40208e46"}},{"code_sha256_prefix":"e69c0b8f30904b6d","entry":"get_label_wh_xy_minmax","repo":"shiyongming/calib-dataset-eval","repo_kind":"listed","path":"datasetapi/voc_dataset/extract_info_from_voc.py","file_url":"https://github.com/shiyongming/calib-dataset-eval/blob/HEAD/datasetapi/voc_dataset/extract_info_from_voc.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"e69c0b8f30904b6d"}},{"code_sha256_prefix":"d8571973ca7f8f6f","entry":"get_label_wh_xy_minmax","repo":"shiyongming/calib-dataset-eval","repo_kind":"listed","path":"datasetapi/voc_dataset/voc_data_processing.py","file_url":"https://github.com/shiyongming/calib-dataset-eval/blob/HEAD/datasetapi/voc_dataset/voc_data_processing.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"d8571973ca7f8f6f"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}