{"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/fractional-skipping-towards-finer-grained","title":"Fractional Skipping: Towards Finer-Grained Dynamic CNN Inference","arxiv_id":"2001.00705","date":"2020-01-03","proceeding":null,"authors":["Jianghao Shen","Yonggan Fu","Yue Wang","Pengfei Xu","Zhangyang Wang","Yingyan Lin"],"abstract":"While increasingly deep networks are still in general desired for achieving state-of-the-art performance, for many specific inputs a simpler network might already suffice. Existing works exploited this observation by learning to skip convolutional layers in an input-dependent manner. However, we argue their binary decision scheme, i.e., either fully executing or completely bypassing one layer for a specific input, can be enhanced by introducing finer-grained, \"softer\" decisions. We therefore propose a Dynamic Fractional Skipping (DFS) framework. The core idea of DFS is to hypothesize layer-wise quantization (to different bitwidths) as intermediate \"soft\" choices to be made between fully utilizing and skipping a layer. For each input, DFS dynamically assigns a bitwidth to both weights and activations of each layer, where fully executing and skipping could be viewed as two \"extremes\" (i.e., full bitwidth and zero bitwidth). In this way, DFS can \"fractionally\" exploit a layer's expressive power during input-adaptive inference, enabling finer-grained accuracy-computational cost trade-offs. It presents a unified view to link input-adaptive layer skipping and input-adaptive hybrid quantization. Extensive experimental results demonstrate the superior tradeoff between computational cost and model expressive power (accuracy) achieved by DFS. More visualizations also indicate a smooth and consistent transition in the DFS behaviors, especially the learned choices between layer skipping and different quantizations when the total computational budgets vary, validating our hypothesis that layer quantization could be viewed as intermediate variants of layer skipping. Our source code and supplementary material are available at \\link{https://github.com/Torment123/DFS}.","url_abs":"https://arxiv.org/abs/2001.00705v1","url_pdf":"https://arxiv.org/pdf/2001.00705v1.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":"fractional-skipping-towards-finer-grained","repo_url":"https://github.com/Torment123/DFS","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"quantization","task_name":"Quantization"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2001.00705","atlas_url":"https://app.syntology.ai/?focus=2001.00705","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2001.00705"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+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":"deterministic:regex_extraction","url":"https://github.com/mit-han-lab/haq-release","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"deterministic:regex_extraction","url":"https://github.com/Torment123/DFS","reach":null}],"summary":{"ran":8,"ran_draft_wrong":3,"ran_honours":3,"ran_fixture":1,"unverified":9},"by_repo_kind":{"official":{"samples":12,"ran":6,"repositories":1},"found_in_text":{"samples":12,"ran":9,"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":12,"samples":[{"code_sha256_prefix":"b61afbb33cf81a80","entry":"QuantMeasure","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b61afbb33cf81a80"}},{"code_sha256_prefix":"b6077b00a86467bb","entry":"RNNGate","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b6077b00a86467bb"}},{"code_sha256_prefix":"cbdc3eb53675a6f2","entry":"SoftRNNGate","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"cbdc3eb53675a6f2"}},{"code_sha256_prefix":"bc6ca135467cad70","entry":"conv2d_biprec","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"bc6ca135467cad70"}},{"code_sha256_prefix":"db82a4013a44fb42","entry":"conv_1x1_bn","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenetv3.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenetv3.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"db82a4013a44fb42"}},{"code_sha256_prefix":"bc660f7845db5634","entry":"conv_1x1_bn","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenetv2.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenetv2.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"bc660f7845db5634"}},{"code_sha256_prefix":"84a4cf301e929085","entry":"conv_bn","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenetv3.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenetv3.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"84a4cf301e929085"}},{"code_sha256_prefix":"247c2f31dd34327d","entry":"conv_bn","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenet.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"247c2f31dd34327d"}},{"code_sha256_prefix":"4e64cf99f91fea92","entry":"conv_bn","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenetv2.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenetv2.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4e64cf99f91fea92"}},{"code_sha256_prefix":"a972ad175e8bda7f","entry":"conv_dw","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenet.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"a972ad175e8bda7f"}},{"code_sha256_prefix":"63ec083689f80f47","entry":"make_divisible","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"models/mobilenetv2.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/models/mobilenetv2.py","link_basis":"harvester_set","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"63ec083689f80f47"}},{"code_sha256_prefix":"7d546c0310d1c591","entry":"quantize","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"7d546c0310d1c591"}},{"code_sha256_prefix":"f5f448783f152da8","entry":"quantize_grad","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"f5f448783f152da8"}},{"code_sha256_prefix":"c83e49880d0e8a07","entry":"sample_batch_indexes","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"lib/rl/memory.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/lib/rl/memory.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c83e49880d0e8a07"}},{"code_sha256_prefix":"b5cc72675b688b00","entry":"zeroed_observation","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"lib/rl/memory.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/lib/rl/memory.py","link_basis":"plan_row","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"b5cc72675b688b00"}},{"code_sha256_prefix":"756d13995db71fff","entry":"QConv2d","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"756d13995db71fff"}},{"code_sha256_prefix":"9839bc64a4774f55","entry":"ResNetRecurrentGateSP","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"9839bc64a4774f55"}},{"code_sha256_prefix":"1a2456136d59fff3","entry":"UniformQuantize","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1a2456136d59fff3"}},{"code_sha256_prefix":"753ba41bd9a74e32","entry":"UniformQuantizeGrad","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"753ba41bd9a74e32"}},{"code_sha256_prefix":"e50cc160a435968b","entry":"conv3x3","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"e50cc160a435968b"}},{"code_sha256_prefix":"850e0644d35c1376","entry":"get_dataset","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"lib/utils/data_utils.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/lib/utils/data_utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"850e0644d35c1376"}},{"code_sha256_prefix":"8e7cf364b572ce56","entry":"get_split_train_dataset","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"lib/utils/data_utils.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/lib/utils/data_utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"8e7cf364b572ce56"}},{"code_sha256_prefix":"b6f41456f1266f92","entry":"repackage_hidden","repo":"Torment123/DFS","repo_kind":"official","path":"models.py","file_url":"https://github.com/Torment123/DFS/blob/HEAD/models.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b6f41456f1266f92"}},{"code_sha256_prefix":"d0be8747b3078aa4","entry":"train","repo":"mit-han-lab/haq-release","repo_kind":"found_in_text","path":"rl_quantize.py","file_url":"https://github.com/mit-han-lab/haq-release/blob/HEAD/rl_quantize.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d0be8747b3078aa4"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}