pulsatrix
Loading...
Searching...
No Matches
pulsatrix::ConservationResult Struct Reference

The result of comparing a relevance-propagation step's input and output totals. More...

#include <lrp_conservation.hpp>

Public Member Functions

float delta () const
 |relevance_in_sum - relevance_out_sum| – 0 is perfect conservation.
 

Public Attributes

float relevance_in_sum
 
float relevance_out_sum
 

Detailed Description

The result of comparing a relevance-propagation step's input and output totals.

Note
LRP's defining property is that relevance is conserved layer-to-layer – the sum of relevance at any layer should equal the sum at the next (up to the small absorption epsilon-rule variants introduce). Before this type existed, that check lived only as test-only local lambdas in lrp_conservation_test.cpp/stability_test.cpp; this promotes it to a real, reusable API so non-test code (the ExplanationScoreCard's "trustworthiness" tile) can compute the same number without duplicating the math.

Member Function Documentation

◆ delta()

float pulsatrix::ConservationResult::delta ( ) const

|relevance_in_sum - relevance_out_sum| – 0 is perfect conservation.

Member Data Documentation

◆ relevance_in_sum

float pulsatrix::ConservationResult::relevance_in_sum

◆ relevance_out_sum

float pulsatrix::ConservationResult::relevance_out_sum

The documentation for this struct was generated from the following file: