-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support nested Flux Chains in LRP #119
Conversation
removes `LastNTypeRule`, which is of limited use
flattens both model and rules by default.
This is required for chains of chains. It also allows for small performance optimizations, e.g. defining `modify_layer(::Rule, layer) = nothing` for rules without layer modifications.
Remove duplicate include of `test/vgg11.jl`
- also supports Parallel layers - add tests
Codecov Report
@@ Coverage Diff @@
## master #119 +/- ##
==========================================
+ Coverage 92.29% 93.18% +0.89%
==========================================
Files 17 18 +1
Lines 558 646 +88
==========================================
+ Hits 515 602 +87
- Misses 43 44 +1
|
Fixes `MethodError: no method matching iterate(::Base.Iterators.Reverse{ChainTuple{Tuple{ZeroRule}}})`
Benchmark resultJudge resultBenchmark Report for /home/runner/work/ExplainableAI.jl/ExplainableAI.jlJob Properties
ResultsA ratio greater than
Benchmark Group ListHere's a list of all the benchmark groups executed by this job:
Julia versioninfoTarget
Baseline
Target resultBenchmark Report for /home/runner/work/ExplainableAI.jl/ExplainableAI.jlJob Properties
ResultsBelow is a table of this job's results, obtained by running the benchmarks.
Benchmark Group ListHere's a list of all the benchmark groups executed by this job:
Julia versioninfo
Baseline resultBenchmark Report for /home/runner/work/ExplainableAI.jl/ExplainableAI.jlJob Properties
ResultsBelow is a table of this job's results, obtained by running the benchmarks.
Benchmark Group ListHere's a list of all the benchmark groups executed by this job:
Julia versioninfo
Runtime information
|
Closes #90.
This PR adds support for Flux models that are nested
Chain
s containing otherChain
s.It is a large step towards #10 and a
v0.6
release that supports ResNets.Changes:
Chain
s containing otherChain
s.ChainTuple
andParallelTuple
to maintain model structure on outputs without type piracychainmap
,chainzip
,chainall
,chainflatten
,chainkeys
insrc/flux_chain_utils.jl
Breaking changes:
LRP
keyword argumentis_flat=false
is now calledflatten=true
check_model
(replaced by non-exportedcheck_lrp_compat
)lrp!
calls now take an extra argumentlayer
, avoiding copies of unmodified layersLastNTypeRule
head_tail
,collect_activations
,has_activation_fn