Skip to content

About

Single-observation EP/FXT A+B source detection, native spectral extraction, joint fitting, and flux catalogs

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

English | 简体中文

FXT Single

Create a flux catalog from one Einstein Probe / FXT Level 3 observation: A/B merged detection → native spectral extraction → joint fitting → catalog. The tool currently supports FF-mode FXTA and FXTB data from the same observation.

Configure the environment once, then run from an EP download directory. Input files are found automatically.

Installation and setup

Prepare CIAO 4.18 (with Sherpa / XSPEC), HEASoft, FXTDAS 1.30 and the FXT CALDB using their official installation tutorials. In an initialized CIAO 4.18 environment, clone this repository and install the tool:

git clone https://github.com/sywang0302/fxt-single.git
cd fxt-single
python -m pip install .

fxt-single setup \
  --ciao-bin /path/to/ciao-4.18/bin \
  --headas /path/to/heasoft \
  --caldb /path/to/CALDB \
  --ep-source /path/to/fxtsoftv1.30

setup creates a private FXTDAS installation with the catalog adapters and saves reusable paths to ~/.config/fxt-single/environment.json. Paths found in the current environment may be omitted. To reuse an adapted installation, use --ep-root /path/to/FXTDAS instead of --ep-source. Scientific software and CALDB are supplied separately.

--fxt-python optionally selects the Python executable for EP calibration tools. It defaults to the Python running fxt-single; omit it when that Python already contains the EP dependencies. See the setup example using actual local paths for a working example with separate interpreters.

Use setup --env-file /path/to/environment.json to choose a settings file. The environment template contains reusable paths; relative paths are resolved from that file's directory.

Usage

# Initialize CIAO 4.18 following its official instructions first.
cd /download/OBS_ID/fxt

# 1.69e20 is only an example for the 3C273 field: use your target's Galactic NH in cm^-2.
fxt-single --nh 1.69e20

# Resume the same inputs and output with default parameters; NH is recovered from the run.
fxt-single

The tool finds A/B clean events, matching MKF files and available RMFs. When no matching RMF is present, it generates one from CALDB. Clean events must contain native GTIs. Outputs are written to fxt_single_output/ under the scanned directory; downloaded inputs are read without modification.

Inspect file selection, check dependencies or pass the directory directly:

fxt-single scan /download/OBS_ID/fxt
fxt-single check /download/OBS_ID/fxt --nh 1.69e20
fxt-single /download/OBS_ID/fxt --nh 1.69e20
# fxt-single run /download/OBS_ID/fxt is equivalent to the default command above.

scan lists matched inputs without executing science tools. Use --obsid OBS_ID when several observations are present. Ambiguous HL products or processing versions require explicit selection. --obsid does not change the output directory: use a new --output, such as --output results_OBS_ID, when changing observations or parameters. Output paths are relative to the scanned directory.

NH depends on sky position. For repeated work on one field, save a default with fxt-single setup --nh 1.69e20 or set spectra.nh_cm2 in the environment file. Override it with --nh for a different field. To resume a run with custom science parameters, repeat those parameters; only NH is recovered automatically.

Select an environment file with --env-file or FXT_SINGLE_CONFIG. Individual environment variables and their precedence are described in the setup guide.

Parameters and examples

Parameter Default Option
Full / fitting band 0.3–5 keV --band 0.3 5
Soft / hard bands 0.3–2.3 / 2.3–5 keV --soft-band 0.3 2.3 --hard-band 2.3 5
Detection-significance aperture R70 --detect-eef 0.7
Native spectral-extraction aperture R90 --extract-eef 0.9
wavdetect PSF map R50 --wavdetect-eef 0.5
wavdetect thresholds sigthresh=1e-6, expthresh=0.01 --sigthresh 1e-6 --expthresh 0.01
wavdetect scales √2, 2, 2√2, 4, 4√2, 8, 8√2, 16 pixels e.g. --scales '2 4 8 16'
Galactic NH Target-specific --nh or spectra.nh_cm2

The three EEF settings are independent and support 0.1–0.95. Soft and hard bands must partition the full band without gaps or overlaps; count bands include the lower edge and exclude the upper edge. Use --stop-after detect for a resumable detection checkpoint. See defaults.json for the complete defaults.

Run these examples from the repository root, replacing the example NH:

bash examples/01_default.sh /download/OBS_ID/fxt 1.69e20
bash examples/02_custom_band.sh /download/OBS_ID/fxt 1.69e20
bash examples/03_apertures.sh /download/OBS_ID/fxt 1.69e20

An optional third argument selects the environment file. Each example uses its own output directory; see the examples. The advanced --config mode remains available for explicit per-file inputs; see the setup guide.

Method and outputs

Full-band wavdetect runs once on the merged A/B image. Selection requires wav significance > 3 and, within at least one common band, Pb < 0.01 and Li–Ma > 3. The default detection-significance aperture is R70; spectral extraction uses R90. When the nominal EEF exceeds 0.5 and overlap fallback is enabled, strictly overlapping nominal circles fall back to R50 for both sources, independently for detection and extraction. EEFs at or below 0.5 retain the requested aperture. Background annuli remain 3–5 times the nominal aperture radius, with neighbors excluded at 1.5 times their nominal radii.

A/B retain their native spectra and responses and share an absorbed power-law model in a joint group_counts(1), W-stat fit using XScflux and Sherpa conf. NH is fixed. Γ is fixed at 1.4 below 70 net fit-band counts and is otherwise free. Responses include the aperture correction; do not divide exported flux by EEF again. The tool retains the catalog PSF / ARF adapters and corrects fractional-second GTI exposure weights; see the adapter notes.

fxt_single_output/
  catalog/catalog.fits     # One row per accepted source
  catalog/catalog.csv
  catalog/catalog.json
  catalog/FIELDS.md        # Fields, units and interval definitions
  candidates.json
  photometry/              # Native spectra, responses and fit records
  resolved_config.json     # Actual inputs, parameters and NH
  run.log
  status.json

Fluxes are in erg cm^-2 s^-1, with observed and Galactic-absorption-corrected values and confidence-interval endpoints. Failed fits retain reasons and null fluxes. _ul90 is the upper endpoint of a two-sided 90% conf interval. Positions have no external astrometric correction and only statistical errors. The tool does not perform cross-observation association, stacking or forced photometry.

See code provenance and validation.

Citation

For now, please cite Wang et al. (2026) when using this tool:

Chandra Lensing-cluster Ultradeep Extragalactic Survey (CLUES) I: A 2 Ms Point-Source Catalog of the Abell 2744 Field, arXiv:2609.17673, DOI: 10.48550/arXiv.2609.17673. ADS · BibTeX. The reference will be updated to the EP DR2 paper when available.

Contact

sywang0302@gmail.com

About

Single-observation EP/FXT A+B source detection, native spectral extraction, joint fitting, and flux catalogs

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages