LiMe: A Line Measuring library (v2 release)#
β¨ Key features#
Integrated and profile-dependent measurements of emission and absorption line fluxes.
Support for including pixel-level uncertainty spectra in calculations.
A flexible configuration system for multi-component profile fitting.
Automated and manual tools to verify line detections.
Interactive plots for visual inspection of inputs and results.
Line labeling conventions compatible with PyNeb.
Flexible output results format, including
.txt,.pdf, multi-page.fits,.asdf, and.xlsxfiles.Support for both long-slit and integrated fiels spectrocopic cubes .fits files.
Tip
Where to find what you need
The Introduction section provides detailed descriptions of LiMeβs main components.
The Guides section offers shorter tutorials for specific tasks.
The Explanations section discusses LiMeβs configuration and results from a scientific point of view.
The Reference section contains comprehensive indexes of LiMe functions.
β¨ LiMe v2 release:#
After a year of improvements, weβre releasing LiMe v2, featuring line database support and a robust band-generation model for a more streamlined workflow:
import lime
# Data location
data_folder = '../doc_notebooks/0_resources/'
cfg_file = f'{data_folder}/long_slit.toml'
fits_file = f'{data_folder}/spectra/gp121903_osiris.fits'
# Load the configuration file
obs_cfg = lime.load_cfg(cfg_file)
# Load the spectroscopic observation
spec = lime.Spectrum.from_file(fits_file, instrument='osiris', redshift=obs_cfg['osiris']['gp121903']['z'])
# Generate the object lines table
lines_frame = spec.retrieve.lines_frame(band_vsigma=120, automatic_grouping=True,
fit_cfg=obs_cfg, obj_cfg_prefix='gp121903_osiris')
# Fit the continuum and confirm the lines via intensity thresholding
spec.fit.continuum(degree_list=[3, 6, 6], emis_threshold=[3, 2, 1.5], log_scale=True, plot_steps=True,)
match_lines = spec.infer.peaks_troughs(lines_frame, emission_shape=True, sigma_threshold=3, plot_steps=True)
# Measure the lines
spec.fit.frame(match_lines, obs_cfg, obj_cfg_prefix='gp121903_osiris')
# Plot the results
spec.plot.spectrum(log_scale=True, rest_frame=True)
spec.plot.grid(fname='lines_grid.png')
# Save the results
spec.save_frame('./gp121903_lines_frame.txt')
πΊ Video introduction:#
Many commands from the LiMe v1 video tutorial are outdated, but it still provides a good insight on LiMe workflow.
π π SpecSy alpha release:#
In our ongoing effort to improve the accessibility of astronomical software and data, we are now releasing the alpha version of SpecSyβan open-source, web-based spectroscopic workspace that includes several LiMe utilities. Try it here: https://specsy.streamlit.app/
π Table of Contents#
Guides
Explanations
Reference