Skip to content

Commit 0fb4bd3

Browse files
authored
Remove ImageNet preprocessing utilities (#159)
1 parent 636b3d8 commit 0fb4bd3

File tree

6 files changed

+1
-57
lines changed

6 files changed

+1
-57
lines changed

README.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,7 @@ model = strip_softmax(model)
4040
model = canonize(model)
4141

4242
# Load input
43-
url = HTTP.URI("https://raw.githubusercontent.com/Julia-XAI/ExplainableAI.jl/gh-pages/assets/heatmaps/castle.jpg")
44-
img = load(url)
45-
input = preprocess_imagenet(img)
46-
input = reshape(input, 224, 224, 3, :) # reshape to WHCN format
43+
input = ... # input in WHCN format
4744

4845
# Run XAI method
4946
composite = EpsilonPlusFlat()

docs/src/api.md

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,6 @@ NoiseAugmentation
2323
InterpolationAugmentation
2424
```
2525

26-
# Input preprocessing
27-
```@docs
28-
preprocess_imagenet
29-
```
30-
3126
# Index
3227
```@index
3328
```

src/ExplainableAI.jl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,9 @@ include("bibliography.jl")
1515
include("utils.jl")
1616
include("input_augmentation.jl")
1717
include("gradient.jl")
18-
include("preprocessing.jl")
1918

2019
export Gradient, InputTimesGradient
2120
export NoiseAugmentation, SmoothGrad
2221
export InterpolationAugmentation, IntegratedGradients
23-
export preprocess_imagenet
2422

2523
end # module

src/preprocessing.jl

Lines changed: 0 additions & 32 deletions
This file was deleted.

test/runtests.jl

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,6 @@ pseudorand(dims...) = rand(MersenneTwister(123), Float32, dims...)
2121
@info "Testing input augmentation..."
2222
include("test_input_augmentation.jl")
2323
end
24-
@testset "ImageNet preprocessing" begin
25-
@info "Testing ImageNet preprocessing..."
26-
include("test_imagenet.jl")
27-
end
2824
@testset "CNN" begin
2925
@info "Testing analyzers on CNN..."
3026
include("test_cnn.jl")

test/test_imagenet.jl

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)