Skip to content

Commit 1180a62

Browse files
committed
Add very basic test
Also add NEWS.md entry
1 parent 617ae2a commit 1180a62

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

NEWS.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Flux Release Notes
22

3+
## v0.13.4
4+
* Added [`PairwiseFusion` layer](https://github.com/FluxML/Flux.jl/pull/1983)
5+
36
## v0.13
47
* After a deprecations cycle, the datasets in `Flux.Data` have
58
been removed in favour of MLDatasets.jl.

test/layers/basic.jl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -350,3 +350,12 @@ end
350350
@test Flux.destructure(m1)[2](z1)[1].weight Flux.destructure(m1v)[2](z1)[1].weight
351351
# Note that Flux.destructure(m1v)[2](z) has a Chain{Tuple}, as does m1v[1:2]
352352
end
353+
354+
@testset "PairwiseFusion" begin
355+
x = (rand(1, 10), rand(30, 10))
356+
layer = PairwiseFusion(+, Dense(1, 30), Dense(30, 10))
357+
y = layer(x)
358+
@test length(y) == 2
359+
@test size(y[1]) == (30, 10)
360+
@test size(y[2]) == (10, 10)
361+
end

0 commit comments

Comments
 (0)