Line-Selection Reference#
This page is the parameter reference for PySME line selection and line-info precomputation. It complements Line Filtering, which focuses more on workflow and examples.
Mental model#
Line selection in PySME is controlled in three layers:
linelist_modeall: synthesize with the full line listdynamic: synthesize with a per-segment filtered subsetauto: deprecated alias ofdynamic
line_select_methodinternal: no external CDR/ALMAX metadata pathcdr: usecentral_depthandline_range_*almax: usealmax_ratioandline_range_*
line_select_policyauto: use method-dependent automatic line-info handlingstrict: require explicit method-specific line-info handling
In practice:
linelist_modedecides whether dynamic filtering is usedline_select_methoddecides how line metadata is generated/interpretedline_select_policydecides how strictly that metadata is enforced
CDR-specific parameters#
sme.line_select_cdr_strength_thres#
Threshold for strong-line selection in CDR mode.
sme.line_select_cdr_bin_width#
Bin width used in CDR strong-line selection.
CDR currently uses the bin-based strong-line helper directly, so there is no
separate cdr_use_bins switch.
ALMAX-specific parameters#
sme.line_select_almax_threshold#
Threshold used by ALMAX-based selection.
If None, it falls back to sme.accrt.
sme.line_select_almax_use_bins#
Boolean switch controlling which ALMAX strong-line rule is used:
False: simple threshold rule usingalmax_ratio >= line_select_almax_thresholdTrue: bin-wise cumulative rule usingflag_strong_lines_by_bins(...)
sme.line_select_almax_bin_width#
Bin width used when line_select_almax_use_bins=True.
Deprecated or legacy parameters#
These are still accepted for backward compatibility, but should not be used in new code.
cdr_database#
Deprecated alias of line_precompute_database.
sme.cdr_N_line_chunk#
Legacy alias of sme.line_select_chunk_size.
sme.cdr_parallel#
Legacy alias of sme.line_select_parallel.
sme.cdr_n_jobs#
Legacy alias of sme.line_select_n_jobs.
sme.strong_depth_thres#
Legacy alias of sme.line_select_cdr_strength_thres.
sme.strong_bin_width#
Legacy compatibility field for bin-width based strong-line selection. Prefer:
sme.line_select_cdr_bin_widthsme.line_select_almax_bin_width
sme.line_select_reuse#
Deprecated.
Non-default values currently only trigger a limited internal reuse path by
keeping line opacity around. This is not a fully developed or stable public
cache policy, and new code should leave it at the default none.
cdr_create#
Legacy-style function argument still used to force regeneration of cached line metadata products. It remains supported, but is not yet replaced by a clearer unified name.
Recommended usage#
CDR workflow#
sme.line_select_method = "cdr"
sme.line_select_policy = "strict"
sme.line_select_recompute = "if_stale"
sme.line_select_parallel = False
sme.line_select_chunk_size = 2000
sme.line_select_cdr_strength_thres = 0.001
sme.line_select_cdr_bin_width = 0.2
sme.line_precompute_database = "/path/to/cache"
ALMAX workflow#
sme.line_select_method = "almax"
sme.line_select_policy = "strict"
sme.line_select_recompute = "if_stale"
sme.line_select_parallel = False
sme.line_select_chunk_size = 2000
sme.line_select_almax_threshold = sme.accrt
sme.line_select_almax_use_bins = False
sme.line_select_almax_bin_width = 0.2
sme.line_precompute_database = "/path/to/cache"