irf_select — Interval Random Frog (IRF) selection¶
Group: Variable selector · Registry tolerance: 1e-06
Description¶
Interval Random Frog (Phase 52)
Registry note — Python
auswahl.IntervalRandomFrog(LSX-UniWue; Yun 2013). Same algorithm as libPLSirf. Default_irf_select_pls4allpath mirrors the same auswahl call withrandom_state=seed, giving bit-exact mask parity. The C++ splitmix64 kernel is opt-in vialegacy=True.
Parameters¶
Name |
Type |
Default |
Notes |
|---|---|---|---|
|
|
|
current public binding signature |
|
|
|
current public binding signature |
|
|
|
current public binding signature |
|
|
|
current public binding signature |
|
|
|
current public binding signature |
|
|
|
current public binding signature |
Explanations¶
Bibliographic source¶
Yun, Y.-H. et al. (2013). An efficient method of wavelength interval selection based on random frog for multivariate spectral calibration. Spectrochimica Acta Part A 111, 31–36. DOI 10.1016/j.saa.2013.03.083. The shipped libPLS-compatible path may differ in details; it is not the random-forest IRF of Basu et al.
Mathematical principle¶
IRF partitions the ordered variables into sliding intervals, uses absolute PLS coefficients to score them, and proposes random changes to the active interval subset. Cross-validated RMSE accepts or rejects proposals and selection frequencies summarize the sampled chain.
Appropriate uses¶
Searching contiguous wavelength intervals with random-frog proposals and a PLS cross-validation objective.
Limits and validation¶
IRF here means Interval Random Frog: it uses no random forest or interaction-aware tree importance, and depends on interval width and chain mixing.
Implementation¶
cpp/src/core/irf_selection.cpp contains no decision trees or random-forest feature importance. Interval width, proposal count, seed, and chain mixing determine the frequency estimates.
Sources and provenance¶
Current implementation: cpp/src/core/irf_selection.cpp.
API and bindings¶
C ABI (ABI 2): n4m_feature_selection_irf_select. Use the linked public header for the exact signature, configuration, and result handles.
Python (verified public re-export):
from n4m.feature_selection.wrapper import IRF
Source signature: IRF(top_k: int, *, n_components: int = 2, n_iterations: int = 100, window_size: int = 5, initial_intervals: int = 5, seed: int = 0) (n4m/_impl/selection.py).
R (source-verified): irf_select(X, Y, n_components, n_iterations = 100L, window_size = 10L, initial_intervals = 10L, top_k = 5L, seed = 0L).
The source signature has additional required inputs, so no example call is fabricated.
MATLAB / Octave (source-verified): irf_select(X, Y, n_components, n_iterations, window_size, ... initial_intervals, top_k, seed).
The source signature has additional required inputs, so no example call is fabricated.
Registry parity references 📐
📐
ref.python_auswahl(python · python) —auswahl0.9.0 · strict (rmse_rel ≤ 1e-06) — Pythonauswahl.IntervalRandomFrog(LSX-UniWue; Yun 2013). Same algorithm as libPLSirfwith pinnedrandom_statefor bit-exact mask parity.
Benchmarks¶
Archived measurement identity. Backend labels in this table are the raw IDs recorded when the benchmark ran (including historical pls4all.* IDs). They preserve measurement provenance and do not describe a current public Python, R, or MATLAB binding; use the source-verified API and bindings section above for current entry points.
Adaptive wall-clock per cell measured against full_matrix.csv. Only backends that implement this method are listed; libraries without the method are omitted.
Verdict · ✓ ref / ≈ ref / ~ shape mark a reference-gate pass at strict / relaxed / qualitative tolerance · ✓ bind = archived binding-harness result agrees with the C++ baseline · ⇄ cross-check = documented by-design selector/RNG/model, noncanonical API/facade convention, or secondary oracle · ✗ divergent · ⚠ error · — not run. The fastest backend per column is marked 🏆.
Reference gate: strict — numeric equivalence (rmse_rel_tol ≤ 1e-06).
Rows tagged with 📐 are the canonical parity references for this method (declared in parity_timing.registry). C++ and external rows show reference parity; archived language-harness rows show binding parity against the C++ backend. Hover the icon for role and tolerance band.
| Backend | Parity | 120×30 (ms) |
|---|---|---|
| Python · archived pls4all benchmark | ||
pls4all.sklearn | ✓ J 0.41 | 2.02 ms🏆 |
| R · archived pls4all benchmark | ||
pls4all.R | ✓ J 0.41 | 2.92 ms |
pls4all.R.formula | ✓ J 0.41 | 3.44 ms |
pls4all.R.mdatools | ✓ J 0.41 | 3.37 ms |
pls4all.R.pls | ✓ J 0.41 | 3.91 ms |
| Backend | Parity | 120×30 (ms) |
|---|---|---|
| Python · archived pls4all benchmark | ||
pls4all.sklearn | ✓ J 0.41 | 1.53 ms🏆 |
| R · archived pls4all benchmark | ||
pls4all.R | ✓ J 0.41 | 2.93 ms |
pls4all.R.formula | ✓ J 0.41 | 3.29 ms |
pls4all.R.mdatools | ✓ J 0.41 | 3.58 ms |
pls4all.R.pls | ✓ J 0.41 | 3.55 ms |
| Backend | Parity | 120×30 (ms) |
|---|---|---|
| Python · archived pls4all benchmark | ||
pls4all.sklearn | ✓ J 0.41 | 1.53 ms🏆 |
| R · archived pls4all benchmark | ||
pls4all.R | ✓ J 0.41 | 2.56 ms |
pls4all.R.formula | ✓ J 0.41 | 3.34 ms |
pls4all.R.mdatools | ✓ J 0.41 | 3.55 ms |
pls4all.R.pls | ✓ J 0.41 | 3.57 ms |
See also: benchmark overview · methods index · interactive dashboard