{"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/optimizing-posterior-samples-for-bayesian","title":"Optimizing Posterior Samples for Bayesian Optimization via Rootfinding","arxiv_id":"2410.22322","date":"2024-10-29","proceeding":null,"authors":["Taiwo A. Adebiyi","Bach Do","Ruda Zhang"],"abstract":"Bayesian optimization devolves the global optimization of a costly objective function to the global optimization of a sequence of acquisition functions. This inner-loop optimization can be catastrophically difficult if it involves posterior sample paths, especially in higher dimensions. We introduce an efficient global optimization strategy for posterior samples based on global rootfinding. It provides gradient-based optimizers with two sets of judiciously selected starting points, designed to combine exploration and exploitation. The number of starting points can be kept small without sacrificing optimization quality. Remarkably, even with just one point from each set, the global optimum is discovered most of the time. The algorithm scales practically linearly to high dimensions, breaking the curse of dimensionality. For Gaussian process Thompson sampling (GP-TS), we demonstrate remarkable improvement in both inner- and outer-loop optimization, surprisingly outperforming alternatives like EI and GP-UCB in most cases. Our approach also improves the performance of other posterior sample-based acquisition functions, such as variants of entropy search. Furthermore, we propose a sample-average formulation of GP-TS, which has a parameter to explicitly control exploitation and can be computed at the cost of one posterior sample. Our implementation is available at https://github.com/UQUH/TSRoots .","url_abs":"https://arxiv.org/abs/2410.22322v4","url_pdf":"https://arxiv.org/pdf/2410.22322v4.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":"optimizing-posterior-samples-for-bayesian","repo_url":"https://github.com/uquh/tsroots","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"bayesian-optimization","task_name":"Bayesian Optimization"},{"task_slug":"thompson-sampling","task_name":"Thompson Sampling"},{"task_slug":"global-optimization","task_name":"global-optimization"}],"methods":[{"method_slug":"gaussian-process","method_name":"Gaussian Process"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2410.22322","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2410.22322"}},"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/UQUH/TSRoots","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/uquh/tsroots","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":4},"by_repo_kind":{"official":{"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":"22c1c48178f5ff1f","entry":"find_max_k_sum_without_dp","repo":"UQUH/TSRoots","repo_kind":"official","path":"src/tsroots/max_k_sum.py","file_url":"https://github.com/UQUH/TSRoots/blob/HEAD/src/tsroots/max_k_sum.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":"22c1c48178f5ff1f"}},{"code_sha256_prefix":"b31ec9b27f95e648","entry":"samples","repo":"UQUH/TSRoots","repo_kind":"official","path":"src/tsroots/max_k_sum.py","file_url":"https://github.com/UQUH/TSRoots/blob/HEAD/src/tsroots/max_k_sum.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":"b31ec9b27f95e648"}},{"code_sha256_prefix":"7fec762fbf97c62a","entry":"scale_Xn","repo":"UQUH/TSRoots","repo_kind":"official","path":"src/tsroots/utils.py","file_url":"https://github.com/UQUH/TSRoots/blob/HEAD/src/tsroots/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":"7fec762fbf97c62a"}},{"code_sha256_prefix":"3c2f286fcd5ad8da","entry":"unscale_X","repo":"UQUH/TSRoots","repo_kind":"official","path":"src/tsroots/utils.py","file_url":"https://github.com/UQUH/TSRoots/blob/HEAD/src/tsroots/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":"3c2f286fcd5ad8da"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}