{"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/learning-specialized-activation-functions-for","title":"Learning Specialized Activation Functions for Physics-informed Neural Networks","arxiv_id":"2308.04073","date":"2023-08-08","proceeding":null,"authors":["Honghui Wang","Lu Lu","Shiji Song","Gao Huang"],"abstract":"Physics-informed neural networks (PINNs) are known to suffer from optimization difficulty. In this work, we reveal the connection between the optimization difficulty of PINNs and activation functions. Specifically, we show that PINNs exhibit high sensitivity to activation functions when solving PDEs with distinct properties. Existing works usually choose activation functions by inefficient trial-and-error. To avoid the inefficient manual selection and to alleviate the optimization difficulty of PINNs, we introduce adaptive activation functions to search for the optimal function when solving different problems. We compare different adaptive activation functions and discuss their limitations in the context of PINNs. Furthermore, we propose to tailor the idea of learning combinations of candidate activation functions to the PINNs optimization, which has a higher requirement for the smoothness and diversity on learned functions. This is achieved by removing activation functions which cannot provide higher-order derivatives from the candidate set and incorporating elementary functions with different properties according to our prior knowledge about the PDE at hand. We further enhance the search space with adaptive slopes. The proposed adaptive activation function can be used to solve different PDE systems in an interpretable way. Its effectiveness is demonstrated on a series of benchmarks. Code is available at https://github.com/LeapLabTHU/AdaAFforPINNs.","url_abs":"https://arxiv.org/abs/2308.04073v1","url_pdf":"https://arxiv.org/pdf/2308.04073v1.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":"learning-specialized-activation-functions-for","repo_url":"https://github.com/leaplabthu/adaafforpinns","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2308.04073","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2308.04073"}},"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":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/leaplabthu/adaafforpinns","reach":{"status":"ok"}}],"summary":{"ran":7,"unverified":3},"by_repo_kind":{"official":{"samples":10,"ran":7,"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":10,"samples":[{"code_sha256_prefix":"9962b7f1cb6fc33c","entry":"Adam","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/choose_optimizer.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/choose_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":"9962b7f1cb6fc33c"}},{"code_sha256_prefix":"0af9ef32a8bd2b8c","entry":"diffusion","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/systems_pbc.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/systems_pbc.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":"0af9ef32a8bd2b8c"}},{"code_sha256_prefix":"92e6e8563c7d4282","entry":"function","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/systems_pbc.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/systems_pbc.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":"92e6e8563c7d4282"}},{"code_sha256_prefix":"a3179c449815c09a","entry":"reaction","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/systems_pbc.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/systems_pbc.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":"a3179c449815c09a"}},{"code_sha256_prefix":"680026eda1992bc6","entry":"sample_random","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/utils.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/utils.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":"680026eda1992bc6"}},{"code_sha256_prefix":"03ee7d7905a1fc9f","entry":"sample_random_interval","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/utils.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/utils.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":"03ee7d7905a1fc9f"}},{"code_sha256_prefix":"825a4200f08d340f","entry":"sample_random_type","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/utils.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/utils.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":"825a4200f08d340f"}},{"code_sha256_prefix":"1d3233e2a8bd0e21","entry":"exact_u","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/visualize.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/visualize.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":"1d3233e2a8bd0e21"}},{"code_sha256_prefix":"46a668d7ec1cbb95","entry":"u_diff","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/visualize.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/visualize.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":"46a668d7ec1cbb95"}},{"code_sha256_prefix":"ad6fe4c9af50735d","entry":"u_predict","repo":"leaplabthu/adaafforpinns","repo_kind":"official","path":"source/visualize.py","file_url":"https://github.com/leaplabthu/adaafforpinns/blob/HEAD/source/visualize.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":"ad6fe4c9af50735d"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}