{"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/deep-neural-networks-for-the-sequential","title":"Sequential Density Ratio Estimation for Simultaneous Optimization of Speed and Accuracy","arxiv_id":"2006.05587","date":"2020-06-10","proceeding":"ICLR 2021 1","authors":["Akinori F. Ebihara","Taiki Miyagawa","Kazuyuki Sakurai","Hitoshi Imaoka"],"abstract":"Classifying sequential data as early and as accurately as possible is a challenging yet critical problem, especially when a sampling cost is high. One algorithm that achieves this goal is the sequential probability ratio test (SPRT), which is known as Bayes-optimal: it can keep the expected number of data samples as small as possible, given the desired error upper-bound. However, the original SPRT makes two critical assumptions that limit its application in real-world scenarios: (i) samples are independently and identically distributed, and (ii) the likelihood of the data being derived from each class can be calculated precisely. Here, we propose the SPRT-TANDEM, a deep neural network-based SPRT algorithm that overcomes the above two obstacles. The SPRT-TANDEM sequentially estimates the log-likelihood ratio of two alternative hypotheses by leveraging a novel Loss function for Log-Likelihood Ratio estimation (LLLR) while allowing correlations up to $N (\\in \\mathbb{N})$ preceding samples. In tests on one original and two public video databases, Nosaic MNIST, UCF101, and SiW, the SPRT-TANDEM achieves statistically significantly better classification accuracy than other baseline classifiers, with a smaller number of data samples. The code and Nosaic MNIST are publicly available at https://github.com/TaikiMiyagawa/SPRT-TANDEM.","url_abs":"https://arxiv.org/abs/2006.05587v3","url_pdf":"https://arxiv.org/pdf/2006.05587v3.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":"deep-neural-networks-for-the-sequential","repo_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"tf","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"deep-neural-networks-for-the-sequential","repo_url":"https://github.com/Akinori-F-Ebihara/LLLR_toymodel","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":null}],"tasks":[{"task_slug":"decision-making","task_name":"Decision Making"},{"task_slug":"density-ratio-estimation","task_name":"Density Ratio Estimation"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2006.05587","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2006.05587"}},"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":"deterministic:regex_extraction","url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Akinori-F-Ebihara/LLLR_toymodel","reach":null}],"summary":{"ran":2,"ran_fixture":2,"unverified":17},"by_repo_kind":{"official":{"samples":17,"ran":2,"repositories":1},"listed":{"samples":4,"ran":2,"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":"99a9b0009e646b84","entry":"CE_lite","repo":"Akinori-F-Ebihara/LLLR_toymodel","repo_kind":"listed","path":"models/losses.py","file_url":"https://github.com/Akinori-F-Ebihara/LLLR_toymodel/blob/HEAD/models/losses.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":"99a9b0009e646b84"}},{"code_sha256_prefix":"9549cebefd92ba63","entry":"LLLR_lite","repo":"Akinori-F-Ebihara/LLLR_toymodel","repo_kind":"listed","path":"models/losses.py","file_url":"https://github.com/Akinori-F-Ebihara/LLLR_toymodel/blob/HEAD/models/losses.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":"9549cebefd92ba63"}},{"code_sha256_prefix":"4ce12fe48cdf3000","entry":"binary_truncated_sprt","repo":"taikimiyagawa/sprt-tandem","repo_kind":"official","path":"utils/performance_metrics.py","file_url":"https://github.com/taikimiyagawa/sprt-tandem/blob/HEAD/utils/performance_metrics.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4ce12fe48cdf3000"}},{"code_sha256_prefix":"37d3cf0b1afae8c1","entry":"calc_binary_llrs","repo":"taikimiyagawa/sprt-tandem","repo_kind":"official","path":"utils/performance_metrics.py","file_url":"https://github.com/taikimiyagawa/sprt-tandem/blob/HEAD/utils/performance_metrics.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"37d3cf0b1afae8c1"}},{"code_sha256_prefix":"1b1d4bd6e98cee84","entry":"KLIEP_lite","repo":"Akinori-F-Ebihara/LLLR_toymodel","repo_kind":"listed","path":"models/losses.py","file_url":"https://github.com/Akinori-F-Ebihara/LLLR_toymodel/blob/HEAD/models/losses.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":"1b1d4bd6e98cee84"}},{"code_sha256_prefix":"dc11f5694b7e7578","entry":"binary_confmx_to_bac","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/performance_metrics.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/performance_metrics.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":"dc11f5694b7e7578"}},{"code_sha256_prefix":"59f9105f519377e9","entry":"binary_llr_loss_func","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"models/losses.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/models/losses.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":"59f9105f519377e9"}},{"code_sha256_prefix":"96672439f1928178","entry":"checkpoint_logger","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/util_ckpt.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/util_ckpt.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":"96672439f1928178"}},{"code_sha256_prefix":"03a548ed70ba1d0c","entry":"confmx_to_metrics","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/performance_metrics.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/performance_metrics.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":"03a548ed70ba1d0c"}},{"code_sha256_prefix":"c3e48b4df760dba8","entry":"decode_feat","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"datasets/data_processing.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/datasets/data_processing.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":"c3e48b4df760dba8"}},{"code_sha256_prefix":"50e5cb9e9fd3ce06","entry":"decode_nosaic_mnist","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"datasets/data_processing.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/datasets/data_processing.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":"50e5cb9e9fd3ce06"}},{"code_sha256_prefix":"61d078878105d29d","entry":"get_batch_norm_layer","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"models/backbones_fe.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/models/backbones_fe.py","link_basis":"harvester_set","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":"61d078878105d29d"}},{"code_sha256_prefix":"a30e73ec3ab8a38a","entry":"get_gradient_DRE","repo":"Akinori-F-Ebihara/LLLR_toymodel","repo_kind":"listed","path":"models/losses.py","file_url":"https://github.com/Akinori-F-Ebihara/LLLR_toymodel/blob/HEAD/models/losses.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":"a30e73ec3ab8a38a"}},{"code_sha256_prefix":"93f9562775b33b2c","entry":"get_ressize_dependent_params","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"models/backbones_fe.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/models/backbones_fe.py","link_basis":"harvester_set","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":"93f9562775b33b2c"}},{"code_sha256_prefix":"393ae5de46d6fe89","entry":"load_yaml","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/misc.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/misc.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":"393ae5de46d6fe89"}},{"code_sha256_prefix":"d451032b3c871d46","entry":"logits_to_confmx","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/performance_metrics.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/performance_metrics.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":"d451032b3c871d46"}},{"code_sha256_prefix":"8175594b88600b6e","entry":"multiplet_loss_func","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"models/losses.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/models/losses.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":"8175594b88600b6e"}},{"code_sha256_prefix":"c761d6a6ea580871","entry":"np_to_tfr_nosaic_mnist","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"make_nmnist.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/make_nmnist.py","link_basis":"harvester_set","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":"c761d6a6ea580871"}},{"code_sha256_prefix":"9797f4b100e6ec78","entry":"read_tfrecords_nosaic_mnist","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"datasets/data_processing.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/datasets/data_processing.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":"9797f4b100e6ec78"}},{"code_sha256_prefix":"3d5d0d12e6b23c3b","entry":"suggest_parameters","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/util_optuna.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/util_optuna.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":"3d5d0d12e6b23c3b"}},{"code_sha256_prefix":"09c06838c2fd140f","entry":"suggest_parameters_fe","repo":"TaikiMiyagawa/SPRT-TANDEM","repo_kind":"official","path":"utils/util_optuna.py","file_url":"https://github.com/TaikiMiyagawa/SPRT-TANDEM/blob/HEAD/utils/util_optuna.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":"09c06838c2fd140f"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}