Skip to content

equib/rc2atomneb

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

rc2atomneb

rc2atomneb.py converts recombination-line source data into AtomNeb-style FITS files for the atomic-data-rc/ directory of AtomNeb-py.

It is a Python analogue of the IDL generator gen_rc_atomneb.pro used by AtomNeb-idl.

Requirements

pip install numpy astropy

Input

Expected source tree:

rc_data/
  rc_collection/
  rc_PPB91/
  rc_SH95/
  rc_he_ii_PFSD12/
  rc_n_iii_FSL13/
  rc_o_iii_SSB17/

The attached short rc_o_iii_SSB17/OIIlines_ABC.txt is enough for parser tests, but it is not the complete SSB17 dataset. To reproduce the full AtomNeb SSB17 FITS files, replace it with the full CDS file OIIlines_ABC from VizieR VI/150.

Output

By default:

python rc2atomneb.py --rc-root ./rc_data --out-dir ./atomic-data-rc

writes:

atomic-data-rc/
  rc_collection.fits
  rc_PPB91.fits
  rc_SH95.fits
  rc_he_ii_PFSD12.fits
  rc_n_iii_FSL13.fits
  rc_o_iii_SSB17.fits
  rc_o_iii_SSB17_orl_case_b.fits

FITS layout

Each FITS file follows the recombination-data layout used by gen_rc_atomneb.pro in AtomNeb-idl:

PRIMARY
List
References
data extensions...

List contains at least:

Aeff_Data
Extension

and some collections include additional line metadata. References contains:

AtomicData
Reference

Data extensions are named from the Aeff_Data field, e.g.

c_iii_aeff
h_ii_aeff_a
he_ii_aeff_PFSD12
n_iii_aeff_1
o_iii_aeff_b_1234

Build selected collections

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc \
  --collections collection,ppb91,sh95

Accepted collection names:

all
collection
ppb91
sh95
pfsd12
fsl13
ssb17

SSB17 options

Make only the compact optical Case B file:

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc \
  --collections ssb17 \
  --ssb17-no-full

Make only the full SSB17 file:

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc \
  --collections ssb17 \
  --ssb17-no-case-b-optical

Notes

  • The script writes FITS image extensions for grid-like effective recombination coefficient arrays, following the IDL mwrfits behavior.
  • The script writes FITS binary table extensions for line lists, references, analytic-fit coefficients, wavelength tables, and branching-ratio tables.
  • The SSB17 parser supports the full CDS OIIlines_ABC file structure and can also parse shortened test files, but shortened files cannot reproduce the full AtomNeb SSB17 products.

Optional SSB17 O II products

The SSB17 O II recombination products are not created by default because the main source table is very large and may not be included in small test archives.

By default:

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc

or:

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc \
  --collections all

creates only:

rc_collection.fits
rc_PPB91.fits
rc_SH95.fits
rc_he_ii_PFSD12.fits
rc_n_iii_FSL13.fits

It does not create:

rc_o_iii_SSB17.fits
rc_o_iii_SSB17_orl_case_b.fits

To request the SSB17 products explicitly:

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc \
  --collections ssb17

or together with the default products:

python rc2atomneb_v3_optional_ssb17.py \
  --rc-root ./rc_data \
  --out-dir ./atomic-data-rc \
  --collections all,ssb17

When SSB17 is requested, the script checks for one of these files:

rc_data/rc_o_iii_SSB17/OIIlines_ABC.txt
rc_data/rc_o_iii_SSB17/OIIlines_ABC

If neither file exists, download the full table from CDS:

https://cdsarc.cds.unistra.fr/ftp/VI/150/DataFiles/OIIlines_ABC

or from the catalog page:

https://cdsarc.cds.unistra.fr/viz-bin/cat/VI/150

Then place it in:

rc_data/rc_o_iii_SSB17/OIIlines_ABC

or:

rc_data/rc_o_iii_SSB17/OIIlines_ABC.txt

The shortened OIIlines_ABC.txt used for parser testing is not sufficient to reproduce the complete AtomNeb SSB17 FITS products.

About

Converts recombination-line data into AtomNeb-style FITS files

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 100.0%