{"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/turnstile-ell-p-leverage-score-sampling-with","title":"Turnstile $\\ell_p$ leverage score sampling with applications","arxiv_id":"2406.00339","date":"2024-06-01","proceeding":null,"authors":["Alexander Munteanu","Simon Omlor"],"abstract":"The turnstile data stream model offers the most flexible framework where data can be manipulated dynamically, i.e., rows, columns, and even single entries of an input matrix can be added, deleted, or updated multiple times in a data stream. We develop a novel algorithm for sampling rows $a_i$ of a matrix $A\\in\\mathbb{R}^{n\\times d}$, proportional to their $\\ell_p$ norm, when $A$ is presented in a turnstile data stream. Our algorithm not only returns the set of sampled row indexes, it also returns slightly perturbed rows $\\tilde{a}_i \\approx a_i$, and approximates their sampling probabilities up to $\\varepsilon$ relative error. When combined with preconditioning techniques, our algorithm extends to $\\ell_p$ leverage score sampling over turnstile data streams. With these properties in place, it allows us to simulate subsampling constructions of coresets for important regression problems to operate over turnstile data streams with very little overhead compared to their respective off-line subsampling algorithms. For logistic regression, our framework yields the first algorithm that achieves a $(1+\\varepsilon)$ approximation and works in a turnstile data stream using polynomial sketch/subsample size, improving over $O(1)$ approximations, or $\\exp(1/\\varepsilon)$ sketch size of previous work. We compare experimentally to plain oblivious sketching and plain leverage score sampling algorithms for $\\ell_p$ and logistic regression.","url_abs":"https://arxiv.org/abs/2406.00339v1","url_pdf":"https://arxiv.org/pdf/2406.00339v1.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":"turnstile-ell-p-leverage-score-sampling-with","repo_url":"https://github.com/Tim907/turnstile-sampling","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"none","reach":{"status":"ok"}}],"tasks":[{"task_slug":"regression-1","task_name":"regression"}],"methods":[{"method_slug":"coresets","method_name":"Coresets"},{"method_slug":"set","method_name":"SET"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2406.00339","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2406.00339"}},"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/Tim907/turnstile-sampling","reach":{"status":"ok"}}],"summary":{"ran":8},"by_repo_kind":{"official":{"samples":8,"ran":8,"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":8,"samples":[{"code_sha256_prefix":"b23d4aa4ec12c6fd","entry":"calc","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/optimizer.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/optimizer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b23d4aa4ec12c6fd"}},{"code_sha256_prefix":"6c4292f048418a9a","entry":"compute_leverage_scores","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/experiments.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/experiments.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"6c4292f048418a9a"}},{"code_sha256_prefix":"1cc6b66c3cb4b45e","entry":"fast_QR","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/experiments.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/experiments.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1cc6b66c3cb4b45e"}},{"code_sha256_prefix":"abe5a31b0c91cad1","entry":"gauss_QR","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/l2s_sampling.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/l2s_sampling.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"abe5a31b0c91cad1"}},{"code_sha256_prefix":"a3e9dd06559dbe64","entry":"l2s_sampling","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/l2s_sampling.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/l2s_sampling.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"a3e9dd06559dbe64"}},{"code_sha256_prefix":"b5a2b5eabd2f630a","entry":"logistic_likelihood","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/optimizer.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/optimizer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b5a2b5eabd2f630a"}},{"code_sha256_prefix":"7bc565b991243f1e","entry":"make_Z","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/datasets.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/datasets.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"7bc565b991243f1e"}},{"code_sha256_prefix":"79088227a6fff92f","entry":"only_keep_k","repo":"Tim907/turnstile-sampling","repo_kind":"official","path":"sketching/optimizer.py","file_url":"https://github.com/Tim907/turnstile-sampling/blob/HEAD/sketching/optimizer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"79088227a6fff92f"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}