Skip to content

Commit fd2912f

Browse files
committed
Fix zeros deprecation
1 parent ea23e3f commit fd2912f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/conv.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,10 +101,10 @@ depthwiseconv!(y::AbstractArray{T,4}, x::AbstractArray{T,4}, w::AbstractArray{T,
101101
depthwiseconv2d!(y, x, w, padding = pad, stride = stride)
102102

103103
∇depthwiseconv_data(dy::A, x::A, w::A; pad = 0, stride = 1) where A<:AbstractArray =
104-
∇depthwiseconv_data!(zeros(x), dy, x, w; pad = pad, stride = stride)
104+
∇depthwiseconv_data!(zero(x), dy, x, w; pad = pad, stride = stride)
105105

106106
∇depthwiseconv_filter(dy::A, x::A, w::A; pad = 0, stride = 1) where A<:AbstractArray =
107-
∇depthwiseconv_filter!(zeros(w), dy, x, w; pad = pad, stride = stride)
107+
∇depthwiseconv_filter!(zero(w), dy, x, w; pad = pad, stride = stride)
108108

109109
∇depthwiseconv_filter!(dw::AbstractArray{T,4}, dy::AbstractArray{T,4}, x::AbstractArray{T,4}, w::AbstractArray{T,4};
110110
pad = 0, stride = 1) where T =

0 commit comments

Comments
 (0)