pub trait TryInferPartialSubbranchProbability {
// Required method
fn try_infer_partial_subbranch_probability(&self) -> Option<f32>;
}
Expand description
Infers the probability of including each child sub-branch partially.
The fraction is in [0..1]
, or None
if we cannot guess.
Required Methods§
fn try_infer_partial_subbranch_probability(&self) -> Option<f32>
Implementors§
impl TryInferPartialSubbranchProbability for Skeleton
Infers the probability of including each child sub-branch partially.
Heuristic:
- Suppose aggregator nodes typically include all children (prob=1.0),
- while dispatch nodes typically pick exactly one child (prob=1 / child_count). We’ll gather a rough average of how many children are “included” in practice.
Implementation:
- For aggregator nodes => “all children used” => partial factor = 1.0
- For dispatch nodes => partial factor ~ (1 / child_count)
- Average these across aggregator & dispatch nodes.
- If no aggregator/dispatch present => return None.