diff --git a/Project.toml b/Project.toml index 319b620..e2ff751 100644 --- a/Project.toml +++ b/Project.toml @@ -15,5 +15,5 @@ ColorSchemes = "3" Colors = "0.12" Crayons = "4" FixedPointNumbers = "0.8" -XAIBase = "3,4" +XAIBase = "4" julia = "1.6" diff --git a/test/test_xaibase.jl b/test/test_xaibase.jl index 074dc71..34100af 100644 --- a/test/test_xaibase.jl +++ b/test/test_xaibase.jl @@ -1,20 +1,21 @@ using XAIBase +input = 42 val = output = [1 6; 2 5; 3 4] text = [["Test", "Text", "Heatmap"], ["another", "dummy", "input"]] output_selection = [CartesianIndex(1, 2), CartesianIndex(3, 4)] # irrelevant -expl = Explanation(val, output, output_selection, :Gradient, :sensitivity) +expl = Explanation(val, input, output, output_selection, :Gradient, :sensitivity) h = heatmap(expl, text) @test_reference "references/Gradient1.txt" repr("text/plain", h[1]) @test_reference "references/Gradient2.txt" repr("text/plain", h[2]) expl = Explanation( - val[:, 1:1], output[:, 1:1], output_selection[1], :Gradient, :sensitivity + val[:, 1:1], input, output[:, 1:1], output_selection[1], :Gradient, :sensitivity ) h = heatmap(expl, text[1]) @test_reference "references/Gradient1.txt" repr("text/plain", only(h)) -expl = Explanation(val, output, output_selection, :LRP, :attribution) +expl = Explanation(val, input, output, output_selection, :LRP, :attribution) h = heatmap(expl, text) @test_reference "references/LRP1.txt" repr("text/plain", h[1]) @test_reference "references/LRP2.txt" repr("text/plain", h[2])