Error of recurrent decimals fixed.

This commit is contained in:
Manjunath Bhat 2019-03-12 02:58:32 +05:30 committed by GitHub
parent 61386c04f8
commit 57a52e3375
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -56,10 +56,12 @@ const ϵ = 1e-7
@test Flux.KLDivergence(y, y1) 4.761838062403337
@test Flux.KLDivergence(y, y) 0
end
y = [1 2 3 4]
y1 = [5.0 6.0 7.0 8.0]
@testset "Hinge" begin
@test Flux.Hinge(y, y1) 0
@test Flux.Hinge(y, 0.2 .* y) 0.33333
@test Flux.Hinge(y, 0.5 .* y) 0.125
end
y = [0.1 0.2 0.3]