pub fn try_differentiate<Op: PrimitiveOp>(
view: &ResolvedView<Op>,
outputs: &[GlobalValKey<Op>],
wrt: &[Op::InputKey],
pass: DiffPassId,
ctx: &mut Op::ADContext,
aliases: &HashMap<Op::InputKey, GlobalValKey<Op>>,
) -> ADRuleResult<LinearFragment<Op>>where
Op::InputKey: ADKey,Expand description
Fallible form of differentiate.
This returns [chainrules::ADRuleError] when a primitive cannot emit a JVP
rule, allowing downstream frontends to surface missing extension rules as
normal errors instead of panics.