{"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/generating-astronomical-spectra-from","title":"Generating astronomical spectra from photometry with conditional diffusion models","arxiv_id":"2211.05556","date":"2022-11-10","proceeding":null,"authors":["Lars Doorenbos","Stefano Cavuoti","Giuseppe Longo","Massimo Brescia","Raphael Sznitman","Pablo Márquez-Neila"],"abstract":"A trade-off between speed and information controls our understanding of astronomical objects. Fast-to-acquire photometric observations provide global properties, while costly and time-consuming spectroscopic measurements enable a better understanding of the physics governing their evolution. Here, we tackle this problem by generating spectra directly from photometry, through which we obtain an estimate of their intricacies from easily acquired images. This is done by using multi-modal conditional diffusion models, where the best out of the generated spectra is selected with a contrastive network. Initial experiments on minimally processed SDSS galaxy data show promising results.","url_abs":"https://arxiv.org/abs/2211.05556v1","url_pdf":"https://arxiv.org/pdf/2211.05556v1.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":"links_only","authors_date_abstract":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license), from the Kaggle arXiv metadata snapshot of 2026-09-12"},"code_links":[{"paper_slug":"generating-astronomical-spectra-from","repo_url":"https://github.com/larsdoorenbos/generate-spectra","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2211.05556","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2211.05556"}},"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/larsdoorenbos/generate-spectra","reach":null}],"summary":{"ran":8,"ran_honours":1,"ran_draft_wrong":1,"unverified":6},"by_repo_kind":{"official":{"samples":16,"ran":10,"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":"7dbaa0d3af9946c4","entry":"Activation","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"7dbaa0d3af9946c4"}},{"code_sha256_prefix":"7eb48a00e07ad73f","entry":"CrossAttention","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"7eb48a00e07ad73f"}},{"code_sha256_prefix":"a90c5fd81174c167","entry":"DefaultClassBuilder","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"a90c5fd81174c167"}},{"code_sha256_prefix":"9d96d3cfa9795e5c","entry":"DownBlock","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"9d96d3cfa9795e5c"}},{"code_sha256_prefix":"e00241be8f072013","entry":"DummyEncoder","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"e00241be8f072013"}},{"code_sha256_prefix":"9e57b13fd1c0cbb7","entry":"ResNetEncoder","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"9e57b13fd1c0cbb7"}},{"code_sha256_prefix":"b882174e4d98b1b9","entry":"SinCosEncoder","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"b882174e4d98b1b9"}},{"code_sha256_prefix":"2b5306125b24e7ca","entry":"UpBlock","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"2b5306125b24e7ca"}},{"code_sha256_prefix":"aafea5a6cd6d98ab","entry":"checkpoint","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.py","link_basis":"first_harvest_node","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"aafea5a6cd6d98ab"}},{"code_sha256_prefix":"d856c2e2a4088353","entry":"get_conv_builder","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"d856c2e2a4088353"}},{"code_sha256_prefix":"e3b8a2acc2178d99","entry":"BasicTransformerBlock","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"e3b8a2acc2178d99"}},{"code_sha256_prefix":"5f89d283defedab0","entry":"GenericUnet","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"5f89d283defedab0"}},{"code_sha256_prefix":"1607e524b1f67f02","entry":"SpatialTransformer","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"1607e524b1f67f02"}},{"code_sha256_prefix":"96f32faddaeb1602","entry":"SpatialTransformerCustom","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"96f32faddaeb1602"}},{"code_sha256_prefix":"da007c56087b5a65","entry":"TimestepEmbedSequential","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"da007c56087b5a65"}},{"code_sha256_prefix":"9980636c8c2c2599","entry":"TimestepEmbedSequentialUp","repo":"larsdoorenbos/generate-spectra","repo_kind":"official","path":"generative/unet.py","file_url":"https://github.com/larsdoorenbos/generate-spectra/blob/HEAD/generative/unet.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":"9980636c8c2c2599"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}