From 51c7ccf733c16d0398ee29f17f2afe4ee9475aa3 Mon Sep 17 00:00:00 2001 From: Carlo Lucibello Date: Tue, 13 Jul 2021 19:42:51 +0200 Subject: [PATCH] Update test/cuda/layers.jl Co-authored-by: Dhairya Gandhi --- test/cuda/layers.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/cuda/layers.jl b/test/cuda/layers.jl index e08a7b60d3..7eb42813b9 100644 --- a/test/cuda/layers.jl +++ b/test/cuda/layers.jl @@ -291,6 +291,6 @@ end @test Array(y_g) == y gs = gradient(() -> sum(m(x)), params(m)) gs_g = gradient(() -> sum(m_g(x_g)), params(m_g)) - @test collect(gs_g[m_g.weight]) ≈ gs[m.weight] + @test Array(gs_g[m_g.weight]) ≈ gs[m.weight] end end