{"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/in-context-freeze-thaw-bayesian-optimization","title":"In-Context Freeze-Thaw Bayesian Optimization for Hyperparameter Optimization","arxiv_id":"2404.16795","date":"2024-04-25","proceeding":null,"authors":["Herilalaina Rakotoarison","Steven Adriaensen","Neeratyoy Mallik","Samir Garibov","Edward Bergman","Frank Hutter"],"abstract":"With the increasing computational costs associated with deep learning, automated hyperparameter optimization methods, strongly relying on black-box Bayesian optimization (BO), face limitations. Freeze-thaw BO offers a promising grey-box alternative, strategically allocating scarce resources incrementally to different configurations. However, the frequent surrogate model updates inherent to this approach pose challenges for existing methods, requiring retraining or fine-tuning their neural network surrogates online, introducing overhead, instability, and hyper-hyperparameters. In this work, we propose FT-PFN, a novel surrogate for Freeze-thaw style BO. FT-PFN is a prior-data fitted network (PFN) that leverages the transformers' in-context learning ability to efficiently and reliably do Bayesian learning curve extrapolation in a single forward pass. Our empirical analysis across three benchmark suites shows that the predictions made by FT-PFN are more accurate and 10-100 times faster than those of the deep Gaussian process and deep ensemble surrogates used in previous work. Furthermore, we show that, when combined with our novel acquisition mechanism (MFPI-random), the resulting in-context freeze-thaw BO method (ifBO), yields new state-of-the-art performance in the same three families of deep learning HPO benchmarks considered in prior work.","url_abs":"https://arxiv.org/abs/2404.16795v3","url_pdf":"https://arxiv.org/pdf/2404.16795v3.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":"in-context-freeze-thaw-bayesian-optimization","repo_url":"https://huggingface.co/spaces/herilalaina/ifbo","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"none","reach":null},{"paper_slug":"in-context-freeze-thaw-bayesian-optimization","repo_url":"https://github.com/automl/ifbo","is_official":0,"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":"hyperparameter-optimization","task_name":"Hyperparameter Optimization"},{"task_slug":"in-context-learning","task_name":"In-Context Learning"}],"methods":[{"method_slug":"absolute-position-encodings","method_name":"Absolute Position Encodings"},{"method_slug":"adam","method_name":"Adam"},{"method_slug":"attention","method_name":"Attention"},{"method_slug":"bpe","method_name":"BPE"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"dropout","method_name":"Dropout"},{"method_slug":"gaussian-process","method_name":"Gaussian Process"},{"method_slug":"hpo","method_name":"HPO"},{"method_slug":"label-smoothing","method_name":"Label Smoothing"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"position-wise-feed-forward-layer","method_name":"Position-Wise Feed-Forward Layer"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"transformer","method_name":"Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2404.16795","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2404.16795"}},"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/automl/ifBO","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/automl/ifbo","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://huggingface.co/spaces/herilalaina/ifbo","reach":null}],"summary":{"ran":2,"ran_draft_wrong":1,"unverified":8},"by_repo_kind":{"named_in_paper":{"samples":11,"ran":3,"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":"ae93b38649dac0ed","entry":"BarDistribution","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"ae93b38649dac0ed"}},{"code_sha256_prefix":"bd43d10d65fb49ec","entry":"Curve","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"bd43d10d65fb49ec"}},{"code_sha256_prefix":"d8a5f8cf9fcd07e2","entry":"_resolve_model_path","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.py","link_basis":"first_harvest_node","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":"d8a5f8cf9fcd07e2"}},{"code_sha256_prefix":"864f165e47883adb","entry":"FILENAME","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"864f165e47883adb"}},{"code_sha256_prefix":"b9bfe00fed47e0b8","entry":"FILE_URL","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"b9bfe00fed47e0b8"}},{"code_sha256_prefix":"eaec9f9ba511916f","entry":"FTPFN","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"eaec9f9ba511916f"}},{"code_sha256_prefix":"6e2a88a13e2d4ad3","entry":"PredictionResult","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"6e2a88a13e2d4ad3"}},{"code_sha256_prefix":"593bf795eb439666","entry":"WEIGHTS_FINAL_NAME","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"593bf795eb439666"}},{"code_sha256_prefix":"81b495c548baefa9","entry":"_fetch_response_with_repeats","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"81b495c548baefa9"}},{"code_sha256_prefix":"539085ca4dfb5e3d","entry":"download_and_decompress","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"539085ca4dfb5e3d"}},{"code_sha256_prefix":"d2413f6e81b6146b","entry":"tokenize","repo":"automl/ifbo","repo_kind":"named_in_paper","path":"ifbo/surrogate.py","file_url":"https://github.com/automl/ifbo/blob/HEAD/ifbo/surrogate.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":"d2413f6e81b6146b"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}