|
5 | 5 | end |
6 | 6 |
|
7 | 7 | @testset "hcat" begin |
8 | | - test_rrule(hcat, randn(3, 2), randn(3), randn(3, 3)) |
9 | | - test_rrule(hcat, rand(), rand(1,2), rand(1,2,1)) |
10 | | - test_rrule(hcat, rand(3,1,1,2), rand(3,3,1,2)) |
| 8 | + test_rrule(hcat, randn(3, 2), randn(3), randn(3, 3); check_inferred=VERSION>v"1.1") |
| 9 | + test_rrule(hcat, rand(), rand(1,2), rand(1,2,1); check_inferred=VERSION>v"1.1") |
| 10 | + test_rrule(hcat, rand(3,1,1,2), rand(3,3,1,2); check_inferred=VERSION>v"1.1") |
11 | 11 | end |
12 | 12 |
|
13 | 13 | @testset "reduce hcat" begin |
|
27 | 27 | end |
28 | 28 |
|
29 | 29 | @testset "vcat" begin |
30 | | - test_rrule(vcat, randn(2, 4), randn(1, 4), randn(3, 4)) |
31 | | - test_rrule(vcat, rand(), rand()) |
32 | | - test_rrule(vcat, rand(), rand(3), rand(3,1,1)) |
33 | | - test_rrule(vcat, rand(3,1,2), rand(4,1,2)) |
| 30 | + test_rrule(vcat, randn(2, 4), randn(1, 4), randn(3, 4); check_inferred=VERSION>v"1.1") |
| 31 | + test_rrule(vcat, rand(), rand(); check_inferred=VERSION>v"1.1") |
| 32 | + test_rrule(vcat, rand(), rand(3), rand(3,1,1); check_inferred=VERSION>v"1.1") |
| 33 | + test_rrule(vcat, rand(3,1,2), rand(4,1,2); check_inferred=VERSION>v"1.1") |
34 | 34 | end |
35 | 35 |
|
36 | 36 | @testset "reduce vcat" begin |
|
45 | 45 | end |
46 | 46 |
|
47 | 47 | @testset "cat" begin |
48 | | - test_rrule(cat, rand(2, 4), rand(1, 4); fkwargs=(dims=1,)) |
49 | | - test_rrule(cat, rand(2, 4), rand(2); fkwargs=(dims=Val(2),)) |
50 | | - test_rrule(cat, rand(), rand(2, 3); fkwargs=(dims=[1,2],)) |
| 48 | + test_rrule(cat, rand(2, 4), rand(1, 4); fkwargs=(dims=1,), check_inferred=VERSION>v"1.1") |
| 49 | + test_rrule(cat, rand(2, 4), rand(2); fkwargs=(dims=Val(2),), check_inferred=VERSION>v"1.1") |
| 50 | + test_rrule(cat, rand(), rand(2, 3); fkwargs=(dims=[1,2],), check_inferred=VERSION>v"1.1") |
51 | 51 | test_rrule(cat, rand(1), rand(3, 2, 1); fkwargs=(dims=(1,2),), check_inferred=false) # infers Tuple{Zero, Vector{Float64}, Any} |
52 | 52 | end |
53 | 53 |
|
54 | 54 | @testset "hvcat" begin |
55 | | - test_rrule(hvcat, 2 ⊢ NoTangent(), rand(ComplexF64, 6)...) |
56 | | - test_rrule(hvcat, (2, 1) ⊢ NoTangent(), rand(), rand(1,1), rand(2,2)) |
57 | | - test_rrule(hvcat, 1 ⊢ NoTangent(), rand(3)' ⊢ rand(1,3), transpose(rand(3)) ⊢ rand(1,3)) |
58 | | - test_rrule(hvcat, 1 ⊢ NoTangent(), rand(0,3), rand(2,3), rand(1,3,1)) |
| 55 | + test_rrule(hvcat, 2 ⊢ NoTangent(), rand(ComplexF64, 6)...; check_inferred=VERSION>v"1.1") |
| 56 | + test_rrule(hvcat, (2, 1) ⊢ NoTangent(), rand(), rand(1,1), rand(2,2); check_inferred=VERSION>v"1.1") |
| 57 | + test_rrule(hvcat, 1 ⊢ NoTangent(), rand(3)' ⊢ rand(1,3), transpose(rand(3)) ⊢ rand(1,3); check_inferred=VERSION>v"1.1") |
| 58 | + test_rrule(hvcat, 1 ⊢ NoTangent(), rand(0,3), rand(2,3), rand(1,3,1); check_inferred=VERSION>v"1.1") |
59 | 59 | end |
60 | 60 |
|
61 | 61 | @testset "fill" begin |
|
0 commit comments