Repository navigation
Expand file tree
/
Copy pathcode.html
More file actions
144 lines (135 loc) · 13.1 KB
/
Copy pathcode.html
File metadata and controls
144 lines (135 loc) · 13.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="author" content="Amanda Stoffers">
<meta name="description" content="Open-source software by Amanda Stoffers: CERIDWEN, the CERIDWEN Ingredient Explorer, the JADES fit explorer and sedpy_jax.">
<title>Code · Amanda Stoffers</title>
<link rel="canonical" href="https://www.amanda-stoffers.de/code.html">
<meta property="og:title" content="Code · Amanda Stoffers">
<meta property="og:url" content="https://www.amanda-stoffers.de/code.html">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=IBM+Plex+Mono:wght@400;600&family=Silkscreen:wght@400;700&family=Press+Start+2P&family=VT323&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/all.min.css">
<link rel="stylesheet" href="assets/css/main.css?v=20261011c">
<link rel="stylesheet" href="assets/css/retro-touch.css?v=20261011c">
<script src="assets/js/main.js?v=20261011c"></script>
</head>
<body>
<nav class="nav">
<div class="nav-inner">
<a class="brand" href="index.html">Amanda Stoffers</a>
<button class="nav-toggle" aria-label="Toggle menu"><i class="fa-solid fa-bars"></i></button>
<ul class="nav-links">
<li><a href="index.html">about</a></li>
<li><a href="publications.html">publications</a></li>
<li><a href="code.html" class="active">code</a></li>
<li><a href="talks.html">talks</a></li>
<li><a href="cv.html">cv</a></li>
<li><button class="theme-toggle" aria-label="Toggle theme"><i class="fa-solid fa-moon"></i></button></li>
</ul>
</div>
</nav>
<main>
<div class="wrap">
<h1>Code & Data</h1>
<p class="muted">Code I have written for stellar population inference, and the interactive pages built on it.
The codes are open source under the MIT licence; issues, pull requests and feature requests are welcome.</p>
<section style="margin-top:32px">
<div class="card">
<h3><i class="fa-solid fa-wand-magic-sparkles" style="color:var(--accent)"></i> CERIDWEN
<span class="repo">· github.com/Espe13/ceridwen</span></h3>
<p><em>CERIDWEN</em> (Comprehensive SED Estimation Routine Involving Data-driven Weight calculatioNs) fits
stellar population models to galaxy photometry and spectra. It is written in JAX and covers the full
forward model: simple stellar populations, nebular emission, dust, and the projection onto the observed
frame. Every step is differentiable and runs on the GPU, so posteriors over stellar mass, star-formation
history, chemical enrichment, dust and redshift can be sampled there directly.</p>
<p>Production runs use a GPU nested slice sampler, and Hamiltonian Monte Carlo and variational inference are
available for the same model. Star-formation histories can be non-parametric with of order one hundred age
bins, with chemical enrichment sampled jointly. On high-redshift galaxies CERIDWEN is a median of 134 times
faster than <span class="muted">Prospector</span> on a CPU.</p>
<div class="meta">
<span class="pill">JAX</span><span class="pill">nested sampling</span>
<span class="pill">Hamiltonian Monte Carlo</span><span class="pill">variational inference</span>
<span class="pill">SED fitting</span><span class="pill">GPU</span>
</div>
<p class="links-inline" style="margin-top:14px">
<a href="/ceridwen/"><i class="fa-solid fa-book-open"></i> Documentation</a>
<a href="https://github.com/Espe13/ceridwen"><i class="fa-brands fa-github"></i> Repository</a>
<a href="https://arxiv.org/abs/2609.30145"><i class="fa-solid fa-file-lines"></i> Method paper (arXiv:2609.30145)</a>
</p>
</div>
<div class="card">
<h3><i class="fa-solid fa-flask" style="color:var(--accent)"></i> CERIDWEN Ingredient Explorer
<span class="repo">· runs in the browser</span></h3>
<p>A browser port of the CERIDWEN forward model, checked against the Python code. You can change the
stellar population, the gas and the dust, add AGN and dust emission, and see how the spectrum changes and
how the galaxy would look through the filters and spectrographs of many telescopes. It can also make mock
catalogues.</p>
<a class="retro-link" href="https://www.amanda-stoffers.de/ceridwen-explorer/#explorer">
<span class="rl-bar"><span>C:\WEB\CERIDWEN\explorer.html</span><span class="rl-btns" aria-hidden="true"><span>_</span><span>□</span><span>x</span></span></span>
<span class="rl-sky">
<svg class="rl-spark s0" viewBox="0 0 5 5" shape-rendering="crispEdges" aria-hidden="true"><path fill="#fff" d="M2 0h1v5h-1zM0 2h5v1h-5z"/><path fill="#7df9ff" d="M2 2h1v1h-1z"/></svg><svg class="rl-spark s1" viewBox="0 0 5 5" shape-rendering="crispEdges" aria-hidden="true"><path fill="#fff" d="M2 0h1v5h-1zM0 2h5v1h-5z"/><path fill="#7df9ff" d="M2 2h1v1h-1z"/></svg><svg class="rl-spark s2" viewBox="0 0 5 5" shape-rendering="crispEdges" aria-hidden="true"><path fill="#fff" d="M2 0h1v5h-1zM0 2h5v1h-5z"/><path fill="#7df9ff" d="M2 2h1v1h-1z"/></svg><svg class="rl-spark s3" viewBox="0 0 5 5" shape-rendering="crispEdges" aria-hidden="true"><path fill="#fff" d="M2 0h1v5h-1zM0 2h5v1h-5z"/><path fill="#7df9ff" d="M2 2h1v1h-1z"/></svg>
<span class="rl-ttl">
<svg class="rl-sprite rl-cat" viewBox="0 0 16 12" shape-rendering="crispEdges" aria-hidden="true"><path fill="#b9a6ff" d="M2 0h1v1h-1zM13 0h1v1h-1zM1 1h1v1h-1zM3 1h1v1h-1zM12 1h1v1h-1zM14 1h1v1h-1zM1 2h1v1h-1zM4 2h1v1h-1zM11 2h1v1h-1zM14 2h1v1h-1zM1 3h1v1h-1zM5 3h1v1h-1zM6 3h1v1h-1zM7 3h1v1h-1zM8 3h1v1h-1zM9 3h1v1h-1zM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-1zM2 8h1v1h-1zM3 8h1v1h-1zM4 8h1v1h-1zM5 8h1v1h-1zM6 8h1v1h-1zM9 8h1v1h-1zM10 8h1v1h-1zM11 8h1v1h-1zM12 8h1v1h-1zM13 8h1v1h-1zM14 8h1v1h-1zM2 9h1v1h-1zM3 9h1v1h-1zM4 9h1v1h-1zM5 9h1v1h-1zM6 9h1v1h-1zM9 9h1v1h-1zM10 9h1v1h-1zM11 9h1v1h-1zM12 9h1v1h-1zM13 9h1v1h-1zM14 9h1v1h-1zM3 10h1v1h-1zM4 10h1v1h-1zM5 10h1v1h-1zM6 10h1v1h-1zM7 10h1v1h-1zM8 10h1v1h-1zM9 10h1v1h-1zM10 10h1v1h-1zM11 10h1v1h-1zM12 10h1v1h-1z"/><path fill="#39ff14" d="M3 6h1v1h-1zM4 6h1v1h-1zM5 6h1v1h-1zM10 6h1v1h-1zM11 6h1v1h-1zM12 6h1v1h-1zM3 7h1v1h-1zM4 7h1v1h-1zM5 7h1v1h-1zM10 7h1v1h-1zM11 7h1v1h-1zM12 7h1v1h-1z"/><path fill="#ff5aa0" d="M7 8h1v1h-1zM8 8h1v1h-1z"/><path fill="#3a2f5c" d="M7 9h1v1h-1zM8 9h1v1h-1z"/><g class="pupils"><path fill="#0b0816" d="M4 6h1v2h-1zM11 6h1v2h-1z"/></g></svg>
<span class="rl-ptwrap"><img class="rl-ptitle" src="assets/img/ceridwen-explorer-title.svg" width="119" height="29" alt="CERIDWEN Ingredient Explorer"><span class="rl-shimmer" aria-hidden="true"></span></span>
<svg class="rl-sprite rl-galaxy" viewBox="0 0 17 15" shape-rendering="crispEdges" aria-hidden="true"><path fill="#c77dff" d="M6 0h1v1h-1zM9 0h1v1h-1zM4 1h1v1h-1zM8 1h1v1h-1zM13 1h1v1h-1zM3 2h1v1h-1zM2 3h1v1h-1zM15 3h1v1h-1zM1 4h1v1h-1zM1 5h1v1h-1zM15 6h1v1h-1zM1 7h1v1h-1zM15 7h1v1h-1zM1 8h1v1h-1zM15 9h1v1h-1zM15 10h1v1h-1zM1 11h1v1h-1zM14 11h1v1h-1zM13 12h1v1h-1zM3 13h1v1h-1zM12 13h1v1h-1zM7 14h1v1h-1zM10 14h1v1h-1z"/><path fill="#7df9ff" d="M9 1h1v1h-1zM10 1h1v1h-1zM6 2h1v1h-1zM7 2h1v1h-1zM8 2h1v1h-1zM11 2h1v1h-1zM5 3h1v1h-1zM11 3h1v1h-1zM12 3h1v1h-1zM4 4h1v1h-1zM12 4h1v1h-1zM3 5h1v1h-1zM13 5h1v1h-1zM3 6h1v1h-1zM13 6h1v1h-1zM3 7h1v1h-1zM13 7h1v1h-1zM3 8h1v1h-1zM13 8h1v1h-1zM3 9h1v1h-1zM13 9h1v1h-1zM4 10h1v1h-1zM12 10h1v1h-1zM4 11h1v1h-1zM5 11h1v1h-1zM11 11h1v1h-1zM5 12h1v1h-1zM8 12h1v1h-1zM9 12h1v1h-1zM10 12h1v1h-1zM6 13h1v1h-1zM7 13h1v1h-1zM8 13h1v1h-1z"/><path fill="#ffd6f5" d="M7 4h1v1h-1zM8 4h1v1h-1zM9 4h1v1h-1zM6 5h1v1h-1zM10 5h1v1h-1zM5 6h1v1h-1zM11 6h1v1h-1zM5 7h1v1h-1zM11 7h1v1h-1zM5 8h1v1h-1zM11 8h1v1h-1zM6 9h1v1h-1zM10 9h1v1h-1zM7 10h1v1h-1zM8 10h1v1h-1zM9 10h1v1h-1z"/><path fill="#ffffff" d="M7 5h1v1h-1zM8 5h1v1h-1zM9 5h1v1h-1zM6 6h1v1h-1zM7 6h1v1h-1zM8 6h1v1h-1zM9 6h1v1h-1zM10 6h1v1h-1zM6 7h1v1h-1zM7 7h1v1h-1zM8 7h1v1h-1zM9 7h1v1h-1zM10 7h1v1h-1zM6 8h1v1h-1zM7 8h1v1h-1zM8 8h1v1h-1zM9 8h1v1h-1zM10 8h1v1h-1zM7 9h1v1h-1zM8 9h1v1h-1zM9 9h1v1h-1z"/></svg>
</span>
<span class="rl-ticker" aria-hidden="true"><span>*** CERIDWEN INGREDIENT EXPLORER *** stars + gas + dust = one galaxy spectrum *** move a slider, watch the light change *** now with AGN, dust emission and mock catalogues *** click to enter *** </span></span>
<span class="rl-foot">
<span class="rl-lede">Change the stars, gas and dust of a model galaxy and watch its spectrum respond, then see how it would look through the filters and spectrographs of many telescopes. Runs a port of the <b>CERIDWEN</b> forward model in your browser.</span>
<span class="rl-enter" aria-hidden="true">ENTER >></span>
</span>
</span>
</a>
</div>
<div class="card">
<h3><i class="fa-solid fa-diagram-project" style="color:var(--accent)"></i> JADES fit explorer
<span class="repo">· interactive catalogue</span></h3>
<p>In <a href="https://jades-survey.github.io/">JADES</a> I lead a value-added catalogue of inferred
physical properties (stellar masses, star-formation histories, dust, metallicities and ionising properties)
for the galaxies with both NIRCam photometry and NIRSpec spectroscopy, fitted jointly with CERIDWEN. The fit
explorer shows these fits and their posteriors in two views: a searchable catalogue table with a page for
each galaxy, and the <em>SED manifold</em>, which shows scaling relations as rotating projections of the
fitted parameter space and can be filtered by redshift and spectroscopic quality.</p>
<div class="meta">
<span class="pill">JWST</span><span class="pill">JADES</span><span class="pill">NIRCam + NIRSpec</span>
<span class="pill">interactive visualisation</span>
</div>
<p class="links-inline" style="margin-top:14px">
<a href="/jades-fit-explorer/manifold.html"><i class="fa-solid fa-cube"></i> SED manifold</a>
<a href="/jades-fit-explorer/index.html"><i class="fa-solid fa-table"></i> Catalogue table</a>
</p>
</div>
<div class="card">
<h3><i class="fa-solid fa-filter" style="color:var(--accent)"></i> sedpy_jax
<span class="repo">· github.com/Espe13/sedpy_jax</span></h3>
<p>A JAX reimplementation of <span class="muted">sedpy</span> (B. D. Johnson) for differentiable filter
handling and broadband photometry on the GPU. It covers transmission curves, AB and Vega magnitudes,
flux-conserving rebinning, air–vacuum conversion, and effective, pivot and zero-point wavelengths, all
vectorised over many filters at once.</p>
<div class="meta">
<span class="pill">JAX</span><span class="pill">photometry</span><span class="pill">filters</span>
</div>
<p class="links-inline" style="margin-top:14px">
<a href="https://github.com/Espe13/sedpy_jax"><i class="fa-brands fa-github"></i> Repository</a>
</p>
</div>
</section>
</div>
</main>
<footer>
<div class="wrap">
<div class="social">
<a href="mailto:[email protected]" aria-label="Email"><i class="fa-solid fa-envelope"></i></a>
<a href="https://orcid.org/0009-0009-5464-3558" aria-label="ORCID"><i class="fa-brands fa-orcid"></i></a>
<a href="https://github.com/Espe13" aria-label="GitHub"><i class="fa-brands fa-github"></i></a>
</div>
© <span id="year"></span> Amanda Stoffers.
</div>
</footer>
<script>document.getElementById("year").textContent = new Date().getFullYear();</script>
</body>
</html>