SPICEAbsorberExtractor
- class salsa.SPICEAbsorberExtractor(ds_filename, ion_name='H I', wavelength_center=None, velocity_res=10, absorber_min=None, frac=0.8)
Bases:
AbsorberExtractorUses SPICE to extract absorbers from a Trident lightray for a given ion species.
- Parameters:
ds_filename (str or YT dataset) – Either Path/name of the dataset to be loaded or the dataset itself
ray_filename (str or Trident ray) – Path/name of the hdf5 ray file to be loaded or the ray already loaded
ion_name (string, optional) – Name of the ion to extract absorbers of Default: “H I”
wavelegnth_center (float, optional) – The specific absorption line to look at (in unit Angstrom). None defaults to strongest absorption line for specified ion (using trident’s ion table). Default: None
velocity_res (float, optional) – Set minimum resolution (in km/s) for SPICE to combine regions Default: 10
absorber_min (float, optional) – Minimum Log Column Density that will be used to define an absorber. If None, defaults to either default for specific ion or 13 Default: None
frac (float, optional) – Parameter defining what fraction of the number density is being accounted for in each iteration of the SPICE method. Must be a number between 0 and 1. Default: 0.8
Methods Summary
get_all_absorbers(ray_list[, fields, units_dict])Create catalog of the given rays using absorber extractor
get_current_absorbers([fields, units_dict])Extract absorbers from the currently loaded ray using SPICE.
Methods Documentation
- get_all_absorbers(ray_list, fields=[], units_dict={})
Create catalog of the given rays using absorber extractor
- Parameters:
ray_list (list of str or trident.ray objects) – List of ray objects or list of trident rays whose absorbers will be extracted
fields (list, optional) – list of yt fields to extract averages of for the absorbers. Defalut: []
units_dict (dict, optional) – dictionary of fields and corresponding astropy units to use for each field. Default: {}
- Returns:
full_df – Catalog of absorber properties.
- Return type:
astropy QTable
- get_current_absorbers(fields=[], units_dict={})
Extract absorbers from the currently loaded ray using SPICE.
Gas features of the absorbers are also extracted. The features include the column density and central velocity of the absorption line (delta_v) as well as requested fields.
- Parameters:
fields (list, optional) – list of yt fields to extract averages of for the absorbers. Defalut: []
units_dict (dict, optional) – dictionary of fields and corresponding astropy units to use for each field. Default: {}
- Returns:
absorber_info – Dataframe of all the absorbers and their corresponding features.
- Return type:
astropy QTable