The James Webb Space Telescope’s NIRSpec instrument captures light from the most distant galaxies in the universe, but extracting meaningful spectra from raw detector data requires sophisticated processing. The Multi-Shutter Assembly (MSA) allows simultaneous observation of hundreds of targets, creating complex data products that demand careful calibration and extraction techniques to reveal the cosmic stories hidden in starlight.
Msaexp provides Python tools for manual spectral extraction directly from JWST NIRSpec exposures, offering researchers precise control over the reduction process. The toolkit handles drizzling and combination of multiple exposures, performs wavelength calibration, and extracts one-dimensional spectra from two-dimensional detector images. With comprehensive Jupyter notebook examples demonstrating the complete pipeline from raw data to science-ready spectra, it supports both prism and medium-resolution grating observations across major survey programs.
Already proven on high-profile datasets including the SMACS-0723 galaxy cluster and various deep field observations, msaexp enables astronomers to push beyond standard pipeline reductions when studying faint, high-redshift galaxies, gravitationally lensed systems, and other challenging targets. As JWST continues revolutionizing our understanding of the early universe, this toolkit provides the precision spectral analysis capabilities needed to extract maximum scientific value from these precious observations.
⭐ Stars: 37
💻 Language: Python
🔗 Repository: gbrammer/msaexp