Astrophysics Source Code Library

Making codes discoverable since 1999

Browsing Codes

Title Date
Abstract Compact
Per Page
[ascl:1909.012] HISS: HI spectra stacker

HISS stacks HI (emission and absorption) spectra in a consistent and reliable manner to enable statistical analysis of average HI properties. It provides plots of the stacked spectrum and reference spectrum with any fitted function, of the stacked noise response, and of the distribution of the integrated fluxes when calculating the uncertainties. It also produces a table containing the integrated flux calculated from the fitted functions and the stacked spectrum, among other output files.

[ascl:1909.011] WVTICs: SPH initial conditions using Weighted Voronoi Tesselations

WVTICs generates glass-like initial conditions for Smoothed Particle Hydrodynamics. Relaxation of the particle distribution is done using an algorithm based on Weighted Voronoi Tesselations; additional particle reshuffling can be enabled to improve over- and undersampled maxima/minima. The WBTICs package includes a full suite of analytical test problems.

[ascl:1909.010] AREPO: Cosmological magnetohydrodynamical moving-mesh simulation code

AREPO is a massively parallel gravity and magnetohydrodynamics code for astrophysics, designed for problems of large dynamic range. It employs a finite-volume approach to discretize the equations of hydrodynamics on a moving Voronoi mesh, and a tree-particle-mesh method for gravitational interactions. AREPO is originally optimized for cosmological simulations of structure formation, but has also been used in many other applications in astrophysics.

[ascl:1909.009] CLOVER: Convolutional neural network spectra identifier and kinematics predictor

CLOVER (Convnet Line-fitting Of Velocities in Emission-line Regions) is a convolutional neural network (ConvNet) trained to identify spectra with two velocity components along the line of sight and predict their kinematics. It works with Gaussian emission lines (e.g., CO) and lines with hyperfine structure (e.g., NH3). CLOVER has two prediction steps, classification and parameter prediction. For the first step, CLOVER segments the pixels in an input data cube into one of three classes: noise (i.e., no emission), one-component (emission line with single velocity component), and two-component (emission line with two velocity components). For the pixels identified as two-components in the first step, a second regression ConvNet is used to predict centroid velocity, velocity dispersion, and peak intensity for each velocity component.

[ascl:1909.008] RascalC: Fast code for galaxy covariance matrix estimation

RascalC quickly estimates covariance matrices from two- or three-point galaxy correlation functions. Given an input set of random particle locations and a two-point correlation function (or input set of galaxy positions), RascalC produces an estimate of the associated covariance for a given binning strategy, with non-Gaussianities approximated by a ‘shot-noise-rescaling’ parameter. For the 2PCF, the rescaling parameter can be calibrated by dividing the particles into jackknife regions and comparing sample to theoretical jackknife covariance. RascalC can also be used to compute Legendre-binned covariances and cross-covariances between different two-point correlation functions.

[ascl:1909.007] EBHLIGHT: General relativistic radiation magnetohydrodynamics with Monte Carlo transport

EBHLIGHT solves the equations of general relativistic radiation magnetohydrodynamics in stationary spacetimes. Fluid integration is performed with the second order shock-capturing scheme HARM (ascl:1209.005) and frequency-dependent radiation transport is performed with the second order Monte Carlo code grmonty (ascl:1306.002). Fluid and radiation exchange four-momentum in an explicit first-order operator-split fashion.

[ascl:1909.006] ChempyMulti: Multi-star Bayesian inference with Chempy

ChempyMulti is an update to Chempy (ascl:1702.011) and provides yield table scoring and multi-star Bayesian inference. This replaces the ChempyScoring package in Chempy. Chempy is a flexible one-zone open-box chemical evolution model, incorporating abundance fitting and stellar feedback calculations. It includes routines for parameter optimization for simulations and observational data and yield table scoring.

[ascl:1909.005] HADES: Hexadecapolar Analysis for Dust Estimation in Simulations (of CMB B-mode thermal dust emission)

HADES analyzse dust levels in simulated CMB galactic dust maps with realistic experimental noise and lensing configurations. It allows detection of dust via its anisotropy properties in CMB B-modes. It also includes techniques for computing null-tests and a rudimentary technique for dedusting.

[ascl:1909.004] TPI: Test Particle Integrator

TPI computes the gravitational dynamics of particles orbiting a supermassive black hole (SBH). A distinction is made to two types of particles: test particles and field particles. Field particles are assumed to move in quasi-static Keplerian orbits around the SBH that precess due to the enclosed mass (Newtonian 'mass precession') and relativistic effects. Otherwise, field-particle-field-particle interactions are neglected. Test particles are integrated in the time-dependent potential of the field particles and the SBH. Relativistic effects are included in the equations of motion (including the effects of SBH spin), and test-particle-test-particle interactions are neglected.

[ascl:1909.003] SecularMultiple: Hierarchical multiple system secular evolution model

SecularMultiple computes the secular (orbit-averaged) gravitational dynamics of hierarchical multiple systems composed of nested binary orbits (simplex-type systems) with any configuration and any number of bodies. A particle can represent a binary or a body. The structure of the system is determined by linking to other particles with the attributes child1 and child2, and tidal interactions and relativistic corrections are included in an ad hoc fashion. SecularMultiple also includes routines for external perturbations such as flybys and supernovae.

[ascl:1909.002] MultiColorFits: Colorize and combine multiple fits images for visually aesthetic scientific plots

MultiColorFits is a tool to colorize and combine multiple fits images for making visually aesthetic scientific plots. The standard method to make color composites by combining fits images programmatically in python is to assign three images as separate red, green, and blue channels. This can produce unsatisfactory results for a variety of reasons, such as when less than three images are available, or additional images are desired to be shown. MultiColorFits breaks these limitations by allowing users to apply any color to a given image, not just red, green, or blue. Composites can then be created from an arbitrary number of images. Controls are included for stretching brightness scales with common functions.

[ascl:1909.001] Auto-multithresh: Automated masking for clean

Auto-multithresh implements an automated masking algorithm for clean. It operates on the residual image within the minor cycle of clean to identify and mask regions of significant emission. It then cascades these significant regions down to lower signal to noise. It includes features to pad the mask to avoid sharp edges and to remove small regions that are unlikely to be significant emission. The algorithm described by this code was incorporated into the tclean task within CASA as auto-multithresh.

[ascl:1908.025] FastCSWT: Fast directional Continuous Spherical Wavelet Transform

FastCSWT performs a directional continuous wavelet transform on the sphere. The transform is based on the construction of the continuous spherical wavelet transform (CSWT) developed by Antoine and Vandergheynst (1999). A fast implementation of the CSWT (based on the fast spherical convolution developed by Wandelt and Gorski 2001) is also provided.

[ascl:1908.024] PYSAT: Python Satellite Data Analysis Toolkit

The Python Satellite Data Analysis Toolkit (pysat) provides a simple and flexible interface for downloading, loading, cleaning, managing, processing, and analyzing space science data. The toolkit supports in situ satellite observations and many different types of ground- and space-based measurements. Its analysis routines are independent of instrument and data source.

[ascl:1908.023] FIRST Classifier: Automated compact and extended radio sources classifier

FIRST Classifier is an on-line system for automated classification of compact and extended radio sources. It is developed based on a trained Deep Convolutional Neural Network Model to automate the morphological classification of compact and extended radio sources observed in the FIRST radio survey. FIRST Classifier is able to predict the morphological class for a single source or for a list of sources as Compact or Extended (FRI, FRII and BENT).

[ascl:1908.022] YMW16: Electron-density model

YMW16 models the distribution of free electrons in the Galaxy, the Magellanic Clouds and the inter-galactic medium and can be used to estimate distances for real or simulated pulsars and fast radio bursts (FRBs) based on their position and dispersion measure. The Galactic model is based on 189 pulsars that have independently determined distances as well as dispersion measures, whereas simpler models are used for the electron density in the MC and the IGM.

[ascl:1908.021] bias_emulator: Halo bias emulator

bias_emulator models the clustering of halos on large scales. It incorporates the cosmological dependence of the bias beyond the mapping of halo mass to peak height. Precise measurements of the halo bias in the simulations are interpolated across cosmological parameter space to obtain the halo bias at any point in parameter space within the simulation cloud. A tool to produce realizations of correlated noise for propagating the modeling uncertainty into error budgets that use the emulator is also provided.

[ascl:1908.020] QLF: Luminosity function analysis code

QLF derives full posterior distributions for and analyzes luminosity functions models; it also models hydrogen and helium reionization. Used with the included homogenized data, the derived luminosity functions can be easily compared with theoretical models or future data sets.

[ascl:1908.019] MAESTROeX: Low Mach number stellar hydrodynamics code

MAESTROeX solves the equations of low Mach number hydrodynamics for stratified atmospheres or stars with a general equation of state. It includes reactions and thermal diffusion and can be used on anything from a single core to 100,000s of processor cores with MPI + OpenMP. MAESTROeX maintains the accuracy of its predecessor MAESTRO (ascl:1010.044) while taking advantage of a simplified temporal integration scheme and leveraging the AMReX software framework for block-structured adaptive mesh refinement (AMR) applications.

[ascl:1908.018] EBAI: Eclipsing Binaries with Artificial Intelligence

Eclipsing Binaries via Artificial Intelligence (EBAI) automates the process of solving light curves of eclipsing binary stars. EBAI is based on the back-propagating neural network paradigm and is highly flexible in construction of neural networks. EBAI comes in two flavors, serial (ebai) and multi-processor (ebai.mpi), and can be run in training, continued training, and recognition mode.

[ascl:1908.017] JPLephem: Jet Propulsion Lab ephemerides package

JPLephem loads and uses standard Jet Propulsion Laboratory (JPL) ephemerides for predicting the position and velocity of a planet or other Solar System body. It is one of the foundations of the Skyfield (ascl:1907.024) astronomy library for Python, and can also be used as a standalone package to generate raw vectors.

[ascl:1908.016] DustCharge: Charge distribution for a dust grain

DustCharge calculates the equilibrium charge distribution for a dust grain of a given size and composition, depending on the local interstellar medium conditions, such as density, temperature, ionization fraction, local radiation field strength, and cosmic ray ionization fraction.

[ascl:1908.015] Analysator: Quantitative analysis of Vlasiator files

Analysator analyzes vlsv files produced by Vlasiator (ascl:1908.014). The code facilitates studies of particle paths, pitch angle distributions, velocity distributions, and more. It can read and write VLSV files and do calculations with the data, plot the real space from VLSV files with Mayavi (ascl:1205.008), and plot the velocity space (both blocks and iso surface) from VLSV files. It can also take cut-throughs, pitch angle distributions, gyrophase angle, and 3d slices, plot variables with sub plots in a clean format, and fit 1D polynomials to data.

[ascl:1908.014] Vlasiator: Hybrid-Vlasov simulation code

Vlasiator is a 6-dimensional Vlasov theory-based simulation. It simulates the entire near-Earth space at a global scale using the kinetic hybrid-Vlasov approach, to study fundamental plasma processes (reconnection, particle acceleration, shocks), and to gain a deeper understanding of space weather.

[ascl:1908.013] BEAST: Bayesian Extinction And Stellar Tool

BEAST (Bayesian Extinction and Stellar Tool) fits the ultraviolet to near-infrared photometric SEDs of stars to extract stellar and dust extinction parameters. The stellar parameters are age (t), mass (M), metallicity (M), and distance (d). The dust extinction parameters are dust column (Av), average grain size (Rv), and mixing between type A and B extinction curves (fA).

[ascl:1908.012] oscode: Oscillatory ordinary differential equation solver

oscode solves oscillatory ordinary differential equations efficiently. It is designed to deal with equations of the form x¨(t)+2γ(t)x˙(t)+ω2(t)x(t)=0, where γ(t) and ω(t) can be given as explicit functions or sequence containers (Eigen::Vectors, arrays, std::vectors, lists) in C++ or as numpy.arrays in Python. oscode makes use of an analytic approximation of x(t) embedded in a stepping procedure to skip over long regions of oscillations, giving a reduction in computing time. The approximation is valid when the frequency changes slowly relative to the timescales of integration, it is therefore worth applying when this condition holds for at least some part of the integration range.

[ascl:1908.011] NuRadioMC: Monte Carlo simulation package for radio neutrino detectors

NuRadioMC simulates ultra-high energy neutrino detectors that rely on the radio detection method, which exploits the radio emission generated in the electromagnetic component of a particle shower following a neutrino interaction. The code simulates the neutrino interaction in a medium, subsequent Askaryan radio emission, propagation of the radio signal to the detector and the detector response. NuRadioMC is a Monte Carlo framework that combines flexibility in detector design with user-friendliness. It includes an event generator, improved modeling of the radio emission, a revisited approach to signal propagation, and increased flexibility and precision in the detector simulation.

[ascl:1908.010] SNAPDRAGONS: Stellar Numbers And Parameters Determined Routinely And Generated Observing N-body Systems

SNAPDRAGONS (Stellar Numbers And Parameters Determined Routinely And Generated Observing N-body Systems) is a simplified version of the population synthesis code Galaxia (ascl:1101.007), using a different process to generate the stellar catalog. It splits each N-body particle from the galaxy simulation into an appropriate number of stellar particles to create a mock catalog of observable stars from the N-body model. SNAPDRAGON uses the same isochrones and extinction map as Galaxia.

[ascl:1908.009] PyRADS: Python RADiation model for planetary atmosphereS

The 1D radiation code PyRADS provides line-by-line spectral resolution. For Earth-like atmospheres, PyRADS currently uses HITRAN 2016 line lists and the MTCKD continuum model. A version for shortwave radiation (scattering) is also available.

[ascl:1908.008] TRISTAN-MP: TRIdimensional STANford - Massively Parallel code

TRISTAN-MP is a fully relativistic Particle-In-Cell (PIC) code for plasma physics computations and self-consistently solves the full set of Maxwell’s equations, along with the relativistic equations of motion for the charged particles. Fields are discretized on a finite 3D or 2D mesh, the computational grid; the code then uses time-centered and space-centered finite difference schemes to advance the equations in time via the Lorentz force equation, and to calculate spatial derivatives, so that the algorithm is second order accurate in space and time. The charges and currents derived from the particles' velocities and positions are then used as source terms to re-calculate the electromagnetic fields. TRISTAN-MP is based on the original TRISTAN code (ascl:2008.025) by O. Buneman (1993).

[ascl:1908.007] MosfireDRP: MOSFIRE Data Reduction Pipeline

MosfireDRP reduces data from the MOSFIRE spectrograph of the Keck Observatory; it produces flat-fielded, wavelength calibrated, rectified, and stacked 2D spectrograms for each slit on a given mask in nearly real time. Background subtraction is performed in two states: a simple pairwise subtraction of interleaved stacks, and then fitting a 2D b-spline model to the background residuals.

[ascl:1908.006] GBKFIT: Galaxy kinematic modeling

GBKFIT performs galaxy kinematic modeling. It can be used to extract morphological and kinematical properties of galaxies by fitting models to spatially resolved kinematic data. The software can also take beam smearing into account by using the knowledge of the line and point spread functions. GBKFIT can take advantage of many-core and massively parallel architectures such as multi-core CPUs and Graphics Processing Units (GPUs), making it suitable for modeling large-scale surveys of thousands of galaxies within a very seasonable time frame. GBKFIT features an extensible object-oriented architecture that supports arbitrary models and optimization techniques in the form of modules; users can write custom modules without modifying GBKFIT’s source code. The software is written in C++ and conforms to the latest ISO standards.

[ascl:1908.005] dips: Detrending periodic signals in timeseries

dips detrends timeseries of strictly periodic signals. It does not assume any functional form for the signal or the background or the noise; it disentangles the strictly periodic component from everything else. It has been used for detrending Kepler, K2 and TESS timeseries of periodic variable stars, eclipsing binary stars, and exoplanets.

[ascl:1908.004] Gramsci: GRAph Made Statistics for Cosmological Information

Gramsci (GRAph Made Statistics for Cosmological Information) computes the general N-point spatial correlation functions of any discrete point set embedded within an Euclidean space of ℝ^n. It uses kd-trees and graph databases to count all possible N-tuples in binned configurations within a given length scale, e.g. all pairs of points or all triplets of points with side lengths. Gramsci can run in serial, OpenMP, MPI and hybrid parallel schemes. It is useful for performing domain decomposition of input catalogs, especially if the catalogs are large or the Rmax value is too large.

[ascl:1908.003] ActSNClass: Active learning for supernova photometric classification

ActSNClass uses a parametric feature extraction method, Random Forest classifier and two learning strategies (uncertainty sampling and random sampling) to performs active learning for supernova photometric classification.

[ascl:1908.002] Molsoft: Molonglo Telescope Observing Software

Molsoft operates, monitors and schedules observations, both through predetermined schedule files and fully dynamically, at the refurbished Molonglo Observatory Synthesis Radio Telescope (MOST). It was developed as part of the UTMOST upgrade of the facility. The software runs a large-scale pulsar timing program; the autonomous observing system and the dynamic scheduler have increased the observing efficiency by a factor of 2-3 in comparison with static scheduling.

[ascl:1908.001] QAC: Quick Array Combinations front end to CASA

QAC (Quick Array Combinations) is a front end to CASA (ascl:1107.013) and calls tools and tasks to help in combining data from a single dish and interferometer. QAC hides some of the complexity of writing CASA scripts and provide a simple interface to array combination tools and tasks in CASA. This project was conceived alongside the TP2VIS (ascl:1904.021) project, where it was used to provide an easier way to call CASA and perform regression tests.

[ascl:1907.032] Astro-SCRAPPY: Speedy Cosmic Ray Annihilation Package in Python

Astro-SCRAPPY detects cosmic rays in images (numpy arrays), based on Pieter van Dokkum's L.A.Cosmic algorithm and originally adapted from written by Malte Tewes. This implementation is optimized for speed, resulting in slight difference from the original code, such as automatic recognition of saturated stars (rather than treating such stars as large cosmic rays, and use of a separable median filter instead of the true median filter. Astro-SCRAPPY is an AstroPy (ascl:1304.002) affiliated package.

[ascl:1907.031] MGB: Interactive spectral classification code

MGB (Marxist Ghost Buster) attacks spectral classification by using an interactive comparison with spectral libraries. It allows the user to move along the two traditional dimensions of spectral classification (spectral subtype and luminosity classification) plus the two additional ones of rotation index and spectral peculiarities. Double-lined spectroscopic binaries can also be fitted using a combination of two standards. The code includes OB2500 v2.0, a standard grid of blue-violet R ~ 2500 spectra of O stars from the Galactic O-Star Spectroscopic Survey, but other grids can be added to MGB.

[ascl:1907.030] Wōtan: Stellar detrending methods

Wōtan provides free and open source algorithms to remove trends from time-series data automatically as an aid to to search efficiently for transits in stellar light curves from surveys. The toolkit helps determine empirically the best tool for a given job, serving as a one-stop solution for various smoothing tasks.

[ascl:1907.029] XDF-GAN: Mock astronomical survey generator

XDF-GAN generates mock galaxy surveys with a Spatial Generative Adversarial Network (SGAN)-like architecture. Mock galaxy surveys are generated from data that is preprocessed as little as possible (preprocessing is only a 99.99th percentile clipping). The outputs can also be tessellated together to create a very large survey, limited in size only by the RAM of the generation machine.

[ascl:1907.028] ROHSA: Separation of diffuse sources in hyper-spectral data

ROHSA (Regularized Optimization for Hyper-Spectral Analysis) reveals the statistical properties of interstellar gas through atomic and molecular lines. It uses a Gaussian decomposition algorithm based on a multi-resolution process from coarse to fine grid to decompose any kind of hyper-spectral observations into a sum of coherent Gaussian. Optimization is performed on the whole data cube at once to obtain a solution with spatially smooth parameters.

[ascl:1907.027] intensitypower: Spectrum multipoles modeler

intensitypower measures and models the auto- and cross-power spectrum multipoles of galaxy catalogs and radio intensity maps presented in spherical coordinates. It can also convert the multipoles to power spectrum wedges P(k,mu) and 2D power spectra P(k_perp,k_par). The code assumes the galaxy catalog is a set of discrete points and the radio intensity map is a pixelized continuous field which includes angular pixelization using healpix, binning in redshift channels, smoothing by a Gaussian telescope beam, and the addition of a Gaussian noise in each cell. The galaxy catalog and radio intensity map are transferred onto an FFT grid, and power spectrum multipoles are measured including curved-sky effects. Both maps include redshift-space distortions.

[ascl:1907.026] MCRGNet: Morphological Classification of Radio Galaxy Network

MCRGNet (Morphological Classification of Radio Galaxy Network) classifies radio galaxies of different morphologies. It is based on the Convolutional Neural Network (CNN), which is trained and applied under a three-step framework: 1.) pretraining the network unsupervisedly with unlabeled samples, 2.) fine-tuning the pretrained network parameters supervisedly with labeled samples, and 3.) classifying a new radio galaxy by the trained network. The code uses a dichotomous tree classifier composed of cascaded CNN based subclassifiers.

[ascl:1907.025] GIST: Galaxy IFU Spectroscopy Tool

GIST (Galaxy IFU Spectroscopy Tool) provides a convenient all-in-one framework for the scientific analysis of fully reduced, (integral-field) spectroscopic data, conducting all the steps from the preparation of input data to the scientific analysis and to the production of publication-quality plots. In its basic set-up, the GIST pipeline extracts stellar kinematics, performs an emission-line analysis, and derives stellar population properties from full spectral fitting and via the measurement of absorption line-strength indices by exploiting pPXF (ascl:1210.002)and GandALF routines. The pipeline is not specific to any instrument or analysis technique, and includes a dedicated visualization routine with a sophisticated graphical user interface for fully interactive plotting of all measurements, spectra, fits, and residuals, as well as star formation histories and the weight distribution of the models.

[ascl:1907.024] Skyfield: High precision research-grade positions for planets and Earth satellites generator

Skyfield computes positions for the stars, planets, and satellites in orbit around the Earth. Its results should agree with the positions generated by the United States Naval Observatory and their Astronomical Almanac to within 0.0005 arcseconds (which equals half a “mas” or milliarcsecond). It computes geocentric coordinates or topocentric coordinates specific to your location on the Earth’s surface. Skyfield accepts AstroPy (ascl:1304.002) time objects as input and can return results in native AstroPy units but is not dependend on AstroPy nor its compiled libraries.

[ascl:1907.023] REVOLVER: REal-space VOid Locations from suVEy Reconstruction

REVOLVER reconstructs real space positions from redshift-space tracer data by subtracting RSD through FFT-based reconstruction (optional) and applies void-finding algorithms to create a catalogue of voids in these tracers. The tracers are normally galaxies from a redshift survey but could also be halos or dark matter particles from a simulation box. Two void-finding routines are provided. The first is based on ZOBOV (ascl:1304.005) and uses Voronoi tessellation of the tracer field to estimate the local density, followed by a watershed void-finding step. The second is a voxel-based method, which uses a particle-mesh interpolation to estimate the tracer density, and then uses a similar watershed algorithm. Input data files can be in FITS format, or ASCII- or NPY-formatted data arrays.

[ascl:1907.022] CMDPT: Color Magnitude Diagrams Plot Tool

CMD Plot Tool calculates and plots Color Magnitude Diagrams (CMDs) from astronomical photometric data, e.g. of a star cluster observed in two filter bandpasses. It handles multiple file formats (plain text, DAOPHOT .mag files, ACS Survey of Galactic Globular Clusters .zpt files) to generate professional and customized plots without a steep learning curve. It works “out of the box” and does not require any installation of development environments, additional libraries, or resetting of system paths. The tool is available as a single application/executable file with the source code. Sample data is also bundled for demonstration. CMD Plot Tool can also convert DAOPHOT magnitude files to CSV format.

[ascl:1907.021] PRISM: Probabilistic Regression Instrument for Simulating Models

PRISM analyzes scientific models using the Bayes linear approach, the emulation technique, and history matching to construct an approximation ('emulator') of any given model. The software facilitates and enhances existing MCMC methods by restricting plausible regions and exploring parameter space efficiently and can be used as a standalone alternative to MCMC for model analysis, providing insight into the behavior of complex scientific models. PRISM stores results in HDF5-files and can be executed in serial or MPI on any number of processes. It accepts any type of model and comparison data and can reduce relevant parameter space by factors over 100,000 using only a few thousand model evaluations.

[ascl:1907.020] GaussPy+: Gaussian decomposition package for emission line spectra

GaussPy+ is a fully automated Gaussian decomposition package for emission line spectra. It is based on GaussPy (ascl:1907.019) and offers several improvements, including automating preparatory steps and providing an accurate noise estimation, improving the fitting routine, and providing a routine to refit spectra based on neighboring fit solutions. GaussPy+ handles complex emission and low to moderate signal-to-noise values.

Would you like to view a random code?