diff --git a/Project.toml b/Project.toml index 170f0efe56..524be02d8e 100644 --- a/Project.toml +++ b/Project.toml @@ -25,6 +25,9 @@ NNlib = "872c559c-99b0-510c-b3b7-b6c96a88d5cd" Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" YaoBlocks = "418bc28f-b43b-5e0b-a6e7-61bbc1a2c1df" +[sources.ReactantCore] +path = "lib/ReactantCore" + [extensions] ReactantAbstractFFTsExt = "AbstractFFTs" ReactantArrayInterfaceExt = "ArrayInterface" @@ -49,12 +52,10 @@ ReactantCore = "0.1.2" Reactant_jll = "0.0.25" Scratch = "1.2" Statistics = "1.10" +YaoBlocks = "0.13" julia = "1.10" [extras] Adapt = "79e6a3ab-5dfb-504d-930d-738a2a938a0e" ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9" NNlib = "872c559c-99b0-510c-b3b7-b6c96a88d5cd" - -[sources] -ReactantCore = { path = "lib/ReactantCore" } diff --git a/test/ops.jl b/test/ops.jl index 637e4dd3a1..58c486f16c 100644 --- a/test/ops.jl +++ b/test/ops.jl @@ -320,7 +320,11 @@ end @test log.(Array(x)) ≈ @jit Ops.log(x) end -@testset "logistic" begin end +@testset "logistic" begin + x = ConcreteRArray([0.0, 1.0, 2.0, 3.0]) + l(x) = 1 / (1 + exp(-x)) + @test l.(Array(x)) ≈ @jit Ops.logistic(x) +end @testset "maximum" begin x = ConcreteRArray([false, false, true, true]) @@ -798,4 +802,8 @@ end @test (; values=[4, 3], indices=[3, 2]) == @jit Ops.top_k(x, 2) end -@testset "zeta" begin end +@testset "zeta" begin + s = ConcreteRArray([1.0, 2.0, 50.0]) + z = ConcreteRArray([1e-8, 0.001, 2.0]) + @test SpecialFunctions.zeta.(Array(s), Array(z)) ≈ @jit Ops.zeta(s, z) +end