pub fn fit_with_scratch(
samples: &[TreeSample],
max_depth: usize,
min_samples_leaf: usize,
max_nodes: usize,
min_rel_var_reduction: f64,
scratch: &mut FitScratch,
) -> SerializedTreeExpand description
Fit a tree reusing the caller-provided scratch arena. After the first
call the arena retains its capacity, so subsequent fits do not allocate.
The logic is identical to fit(), only the temporary buffers are reused.