Skip to content

Commit ef4f22e

Browse files
author
Avik Pal
committed
Typo
1 parent 08d514f commit ef4f22e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/nnpack/libnnpack.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ function nnp_relu_output(batch_size, channels, input, output, negative_slope, th
1515
@check ccall((:nnp_relu_output, libnnpack), nnp_status, (Csize_t, Csize_t, Ptr{Cfloat}, Ptr{Cfloat}, Cfloat, pthreadpool_t), batch_size, channels, input, output, negative_slope, threadpool)
1616
end
1717

18-
function nnp_relu_output(x::Array{Float32,N}, y::Array{Float32,N}; negative_slope::Float = 0.0, threadpool = shared_threadpool[]) where {N}
18+
function nnp_relu_output(x::Array{Float32,N}, y::Array{Float32,N}; negative_slope::AbstractFloat = 0.0, threadpool = shared_threadpool[]) where {N}
1919
# Investigate why the channel and batch dims need to specified like this
2020
nnp_relu_output(prod(size(x)[N-1:N]), prod(size(x)[1:N-2]), x, y, negative_slope, threadpool)
2121
y
@@ -25,7 +25,7 @@ function nnp_relu_input_gradient(batch_size, channels, grad_output, input, grad_
2525
@check ccall((:nnp_relu_input_gradient, libnnpack), nnp_status, (Csize_t, Csize_t, Ptr{Cfloat}, Ptr{Cfloat}, Ptr{Cfloat}, Cfloat, pthreadpool_t), batch_size, channels, grad_output, input, grad_input, negative_slope, threadpool)
2626
end
2727

28-
function nnp_relu_input_gradient(x::Array{Float32,N}, dy::Array{Float32,N}, dx::Array{Float32,N}; negative_slope::Float = 0.0, threadpool = shared_threadpool[]) where {N}
28+
function nnp_relu_input_gradient(x::Array{Float32,N}, dy::Array{Float32,N}, dx::Array{Float32,N}; negative_slope::AbstractFloat = 0.0, threadpool = shared_threadpool[]) where {N}
2929
# Investigate why the channel and batch dims need to specified like this
3030
nnp_relu_input_gradient(Csize_t(prod(size(x)[N-1:N])), prod(size(x)[1:N-2]), dy, x, dx, negative_slope, threadpool)
3131
dx

0 commit comments

Comments
 (0)