Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: LoadError: TypeError: in typeassert, expected Float64, got a value of type ForwardDiff.Dual{Nothing, Float64, 2} #636

Open
prbzrg opened this issue Oct 12, 2021 · 6 comments

Comments

@prbzrg
Copy link
Member

prbzrg commented Oct 12, 2021

When I run this code:

using DiffEqFlux, DifferentialEquations, GalacticOptim, Distributions

nn = Chain(
    Dense(1, 1, tanh),
) |> f32
tspan = (0.0f0, 1.0f0)
sensealg = InterpolatingAdjoint(autojacvec=false)
ffjord_mdl = FFJORD(nn, tspan, Tsit5(); sensealg)

data_dist = Beta(2.0f0, 2.0f0)
train_data = rand(data_dist, 1, 100)

function loss(θ)
    logpx, λ₁, λ₂ = ffjord_mdl(train_data, θ; regularize=false, monte_carlo=false)
    -mean(logpx)
end

adtype = GalacticOptim.AutoZygote()
res = DiffEqFlux.sciml_train(loss, ffjord_mdl.p, ADAM(0.1), adtype; maxiters=10)

I get this error:

ERROR: LoadError: TypeError: in typeassert, expected Float64, got a value of type ForwardDiff.Dual{Nothing, Float64, 2}
Stacktrace:
  [1] setindex!
    @ .\array.jl:841 [inlined]
  [2] macro expansion
    @ .\multidimensional.jl:903 [inlined]
  [3] macro expansion
    @ .\cartesian.jl:64 [inlined]
  [4] macro expansion
    @ .\multidimensional.jl:898 [inlined]
  [5] _unsafe_setindex!(::IndexLinear, ::Array{Float64, 3}, ::WARNING: both Flux and Iterators export "flatten"; uses of it in module DiffEqFlux must be qualified
WARNING: both Flux and Distributions export "params"; uses of it in module DiffEqFlux must be qualified
Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float64, 2}}, ::Int64, ::Base.Slice{Base.OneTo{Int64}}, ::Base.Slice{Base.OneTo{Int64}})
    @ Base .\multidimensional.jl:910
  [6] _setindex!
    @ .\multidimensional.jl:887 [inlined]
  [7] setindex!
    @ .\abstractarray.jl:1267 [inlined]
  [8] setindex!(::Zygote.Buffer{Float64, Array{Float64, 3}}, ::Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float64, 2}}, ::Int64, ::Function, ::Function)
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\tools\buffer.jl:51
  [9] jacobian_fn(f::Chain{Tuple{Dense{typeof(tanh), Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2}}, Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2}}}}}, x::Matrix{Float64})
    @ DiffEqFlux C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\ffjord.jl:152
 [10] ffjord(u::Matrix{Float64}, p::Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2}}, t::Float32, re::Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, e::Matrix{Float64}; regularize::Bool, monte_carlo::Bool)
    @ DiffEqFlux C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\ffjord.jl:183
 [11] #59
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\ffjord.jl:194 [inlined]
 [12] ODEFunction
    @ C:\Users\Hossein Pourbozorg\.julia\packages\SciMLBase\NwvCY\src\scimlfunctions.jl:334 [inlined]
 [13] ParamGradientWrapper
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\derivative_wrappers.jl:17 [inlined]
 [14] vector_mode_dual_eval!
    @ C:\Users\Hossein Pourbozorg\.julia\packages\ForwardDiff\XcU3G\src\apiutils.jl:37 [inlined]
 [15] vector_mode_jacobian(f::DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, x::Vector{Float32}, cfg::ForwardDiff.JacobianConfig{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2, Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2}}})
    @ ForwardDiff C:\Users\Hossein Pourbozorg\.julia\packages\ForwardDiff\XcU3G\src\jacobian.jl:147
 [16] jacobian(f::Function, x::Vector{Float32}, cfg::ForwardDiff.JacobianConfig{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2, Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2}}}, ::Val{true})
    @ ForwardDiff C:\Users\Hossein Pourbozorg\.julia\packages\ForwardDiff\XcU3G\src\jacobian.jl:21
 [17] jacobian(f::Function, x::Vector{Float32}, cfg::ForwardDiff.JacobianConfig{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2, Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Float32}, Float32, 2}}}) (repeats 2 times)
    @ ForwardDiff C:\Users\Hossein Pourbozorg\.julia\packages\ForwardDiff\XcU3G\src\jacobian.jl:19
 [18] jacobian
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\derivative_wrappers.jl:135 [inlined]
 [19] _vecjacobian!(dλ::SubArray{Float64, 1, Vector{Float64}, Tuple{UnitRange{Int64}}, true}, y::Matrix{Float64}, λ::SubArray{Float64, 1, Vector{Float64}, Tuple{UnitRange{Int64}}, true}, p::Vector{Float32}, t::Float32, S::DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}}, isautojacvec::Bool, dgrad::SubArray{Float64, 1, Vector{Float64}, Tuple{UnitRange{Int64}}, true}, dy::Nothing, W::Nothing)
    @ DiffEqSensitivity C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\derivative_wrappers.jl:267
 [20] #vecjacobian!#37
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\derivative_wrappers.jl:224 [inlined]
 [21] (::DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}})(du::Vector{Float64}, u::Vector{Float64}, p::Vector{Float32}, t::Float32)
    @ DiffEqSensitivity C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\interpolating_adjoint.jl:116
 [22] ODEFunction
    @ C:\Users\Hossein Pourbozorg\.julia\packages\SciMLBase\NwvCY\src\scimlfunctions.jl:334 [inlined]
 [23] initialize!(integrator::OrdinaryDiffEq.ODEIntegrator{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, true, Vector{Float64}, Nothing, Float32, Vector{Float32}, Float32, Float64, Float64, Float32, Vector{Vector{Float64}}, ODESolution{Float64, 2, Vector{Vector{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Vector{Float64}}}, ODEProblem{Vector{Float64}, Tuple{Float32, Float32}, true, Vector{Float32}, ODEFunction{true, DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Symbol, CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}, Tuple{Symbol}, NamedTuple{(:callback,), Tuple{CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{true, DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Vector{Float64}}, Vector{Float32}, Vector{Vector{Vector{Float64}}}, OrdinaryDiffEq.Tsit5Cache{Vector{Float64}, Vector{Float64}, Vector{Float64}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}, typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, DiffEqBase.DEStats}, ODEFunction{true, DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, OrdinaryDiffEq.Tsit5Cache{Vector{Float64}, Vector{Float64}, Vector{Float64}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}, typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.DEOptions{Float64, Float64, Float64, Float32, PIController{Rational{Int64}}, typeof(DiffEqBase.ODE_DEFAULT_NORM), typeof(LinearAlgebra.opnorm), Nothing, CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}, typeof(DiffEqBase.ODE_DEFAULT_ISOUTOFDOMAIN), typeof(DiffEqBase.ODE_DEFAULT_PROG_MESSAGE), typeof(DiffEqBase.ODE_DEFAULT_UNSTABLE_CHECK), DataStructures.BinaryHeap{Float32, DataStructures.FasterForward}, DataStructures.BinaryHeap{Float32, DataStructures.FasterForward}, Nothing, Nothing, Int64, Vector{Float32}, Vector{Float64}, Tuple{}}, Vector{Float64}, Float64, Nothing, OrdinaryDiffEq.DefaultInit}, cache::OrdinaryDiffEq.Tsit5Cache{Vector{Float64}, Vector{Float64}, Vector{Float64}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}, typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)})
    @ OrdinaryDiffEq C:\Users\Hossein Pourbozorg\.julia\packages\OrdinaryDiffEq\Zi9Zh\src\perform_step\low_order_rk_perform_step.jl:623
 [24] __init(prob::ODEProblem{Vector{Float64}, Tuple{Float32, Float32}, true, Vector{Float32}, ODEFunction{true, DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Symbol, CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}, Tuple{Symbol}, NamedTuple{(:callback,), Tuple{CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}}}}, SciMLBase.StandardODEProblem}, alg::Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, timeseries_init::Tuple{}, ts_init::Tuple{}, ks_init::Tuple{}, recompile::Type{Val{true}}; saveat::Vector{Float64}, tstops::Vector{Float32}, d_discontinuities::Tuple{}, save_idxs::Nothing, save_everystep::Bool, save_on::Bool, save_start::Bool, save_end::Nothing, callback::CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}, dense::Bool, calck::Bool, dt::Float32, dtmin::Nothing, dtmax::Float32, force_dtmin::Bool, adaptive::Bool, gamma::Rational{Int64}, abstol::Float64, reltol::Float64, qmin::Rational{Int64}, qmax::Int64, qsteady_min::Int64, qsteady_max::Int64, beta1::Nothing, beta2::Nothing, qoldinit::Rational{Int64}, controller::Nothing, fullnormalize::Bool, failfactor::Int64, maxiters::Int64, internalnorm::typeof(DiffEqBase.ODE_DEFAULT_NORM), internalopnorm::typeof(LinearAlgebra.opnorm), isoutofdomain::typeof(DiffEqBase.ODE_DEFAULT_ISOUTOFDOMAIN), unstable_check::typeof(DiffEqBase.ODE_DEFAULT_UNSTABLE_CHECK), verbose::Bool, timeseries_errors::Bool, dense_errors::Bool, advance_to_tstop::Bool, stop_at_next_tstop::Bool, initialize_save::Bool, progress::Bool, progress_steps::Int64, progress_name::String, progress_message::typeof(DiffEqBase.ODE_DEFAULT_PROG_MESSAGE), userdata::Nothing, allow_extrapolation::Bool, initialize_integrator::Bool, alias_u0::Bool, alias_du0::Bool, initializealg::OrdinaryDiffEq.DefaultInit, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ OrdinaryDiffEq C:\Users\Hossein Pourbozorg\.julia\packages\OrdinaryDiffEq\Zi9Zh\src\solve.jl:456
 [25] #__solve#471
    @ C:\Users\Hossein Pourbozorg\.julia\packages\OrdinaryDiffEq\Zi9Zh\src\solve.jl:4 [inlined]
 [26] #solve_call#42
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqBase\OPDgm\src\solve.jl:61 [inlined]
 [27] solve_up(prob::ODEProblem{Vector{Float64}, Tuple{Float32, Float32}, true, Vector{Float32}, ODEFunction{true, DiffEqSensitivity.ODEInterpolatingAdjointSensitivityFunction{DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, Nothing, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Symbol, CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}, Tuple{Symbol}, NamedTuple{(:callback,), Tuple{CallbackSet{Tuple{}, Tuple{DiscreteCallback{DiffEqCallbacks.var"#59#62"{Vector{Float32}}, DiffEqCallbacks.var"#60#63"{DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, DiffEqCallbacks.var"#61#64"{typeof(DiffEqBase.INITIALIZE_DEFAULT), Bool, Vector{Float32}, DiffEqSensitivity.ReverseLossCallback{Vector{Float64}, Vector{Float32}, Matrix{Float64}, Base.RefValue{Int64}, LinearAlgebra.UniformScaling{Bool}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, DiffEqSensitivity.AdjointDiffCache{SciMLBase.UDerivativeWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float32}}, DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Matrix{Float64}}, Nothing, Matrix{Float64}, Matrix{Float64}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Base.OneTo{Int64}, UnitRange{Int64}, LinearAlgebra.UniformScaling{Bool}}}}, typeof(DiffEqBase.FINALIZE_DEFAULT)}}}}}}, SciMLBase.StandardODEProblem}, sensealg::Nothing, u0::Vector{Float64}, p::Vector{Float32}, args::Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}; kwargs::Base.Iterators.Pairs{Symbol, Any, NTuple{6, Symbol}, NamedTuple{(:save_everystep, :save_start, :saveat, :tstops, :abstol, :reltol), Tuple{Bool, Bool, Vector{Float64}, Vector{Float32}, Float64, Float64}}})
    @ DiffEqBase C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqBase\OPDgm\src\solve.jl:87
 [28] #solve#43
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqBase\OPDgm\src\solve.jl:73 [inlined]
 [29] _adjoint_sensitivities(sol::ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, sensealg::InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, alg::Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, g::DiffEqSensitivity.var"#df#235"{Array{Float64, 3}, Colon}, t::Vector{Float32}, dg::Nothing; abstol::Float64, reltol::Float64, checkpoints::Vector{Float32}, corfunc_analytical::Nothing, callback::Nothing, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ DiffEqSensitivity C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\sensitivity_interface.jl:36
 [30] adjoint_sensitivities(::ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, ODEProblem{Matrix{Float64}, Tuple{Float32, Float32}, false, Vector{Float32}, ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, SciMLBase.StandardODEProblem}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, OrdinaryDiffEq.InterpolationData{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Vector{Matrix{Float64}}, Vector{Float32}, Vector{Vector{Matrix{Float64}}}, OrdinaryDiffEq.Tsit5ConstantCache{Float64, Float32}}, DiffEqBase.DEStats}, ::Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, ::Vararg{Any, N} where N; sensealg::InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, kwargs::Base.Iterators.Pairs{Symbol, Nothing, Tuple{Symbol}, NamedTuple{(:callback,), Tuple{Nothing}}})
    @ DiffEqSensitivity C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\sensitivity_interface.jl:6
 [31] (::DiffEqSensitivity.var"#adjoint_sensitivity_backpass#234"{Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, Vector{Float32}, Tuple{}, Colon, NamedTuple{(), Tuple{}}})(Δ::Array{Float64, 3})
    @ DiffEqSensitivity C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqSensitivity\PLNju\src\concrete_solve.jl:272
 [32] ZBack
    @ C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\chainrules.jl:168 [inlined]
 [33] (::Zygote.var"#203#204"{Tuple{NTuple{4, Nothing}, Tuple{Nothing}}, Zygote.ZBack{DiffEqSensitivity.var"#adjoint_sensitivity_backpass#234"{Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, Vector{Float32}, Tuple{}, Colon, NamedTuple{(), Tuple{}}}}})(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\lib\lib.jl:203
 [34] (::Zygote.var"#1734#back#205"{Zygote.var"#203#204"{Tuple{NTuple{4, Nothing}, Tuple{Nothing}}, Zygote.ZBack{DiffEqSensitivity.var"#adjoint_sensitivity_backpass#234"{Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, InterpolatingAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, Vector{Float32}, Tuple{}, Colon, NamedTuple{(), Tuple{}}}}}})(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\ZygoteRules\AIbCs\src\adjoint.jl:67
 [35] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqBase\OPDgm\src\solve.jl:73 [inlined]
 [36] (::typeof((#solve#43)))(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [37] (::Zygote.var"#203#204"{Tuple{NTuple{6, Nothing}, Tuple{Nothing}}, typeof((#solve#43))})(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\lib\lib.jl:203
 [38] (::Zygote.var"#1734#back#205"{Zygote.var"#203#204"{Tuple{NTuple{6, Nothing}, Tuple{Nothing}}, typeof((#solve#43))}})(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\ZygoteRules\AIbCs\src\adjoint.jl:67
 [39] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqBase\OPDgm\src\solve.jl:68 [inlined]
 [40] (::typeof((solve##kw)))(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [41] (::Zygote.var"#203#204"{Tuple{Tuple{Nothing, Nothing, Nothing}, Tuple{Nothing}}, typeof((solve##kw))})(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\lib\lib.jl:203
 [42] (::Zygote.var"#1734#back#205"{Zygote.var"#203#204"{Tuple{Tuple{Nothing, Nothing, Nothing}, Tuple{Nothing}}, typeof((solve##kw))}})(Δ::Array{Float64, 3})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\ZygoteRules\AIbCs\src\adjoint.jl:67
 [43] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\ffjord.jl:208 [inlined]
 [44] (::typeof((#_#58)))(Δ::Tuple{Matrix{Float64}, Nothing, Nothing})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [45] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\ffjord.jl:192 [inlined]
--- the last 2 lines are repeated 1 more time ---
 [48] (::typeof((Any##kw)))(Δ::Tuple{Matrix{Float64}, Nothing, Nothing})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [49] Pullback
    @ C:\Users\Hossein Pourbozorg\Code Projects\Mine\ffjord-report-issues\iss-9.jl:14 [inlined]
 [50] (::typeof((loss)))(Δ::Float64)
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [51] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\train.jl:84 [inlined]
 [52] #203
    @ C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\lib\lib.jl:203 [inlined]
 [53] #1734#back
    @ C:\Users\Hossein Pourbozorg\.julia\packages\ZygoteRules\AIbCs\src\adjoint.jl:67 [inlined]
 [54] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\SciMLBase\NwvCY\src\problems\basic_problems.jl:107 [inlined]
 [55] #203
    @ C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\lib\lib.jl:203 [inlined]
 [56] #1734#back
    @ C:\Users\Hossein Pourbozorg\.julia\packages\ZygoteRules\AIbCs\src\adjoint.jl:67 [inlined]
 [57] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\GalacticOptim\bEh06\src\function\zygote.jl:6 [inlined]
 [58] (::typeof((#159)))(Δ::Float64)
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [59] #203
    @ C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\lib\lib.jl:203 [inlined]
 [60] #1734#back
    @ C:\Users\Hossein Pourbozorg\.julia\packages\ZygoteRules\AIbCs\src\adjoint.jl:67 [inlined]
 [61] Pullback
    @ C:\Users\Hossein Pourbozorg\.julia\packages\GalacticOptim\bEh06\src\function\zygote.jl:8 [inlined]
 [62] (::typeof((#162)))(Δ::Float64)
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface2.jl:0
 [63] (::Zygote.var"#50#51"{typeof((#162))})(Δ::Float64)
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface.jl:41
 [64] gradient(f::Function, args::Vector{Float32})
    @ Zygote C:\Users\Hossein Pourbozorg\.julia\packages\Zygote\Lw5Kf\src\compiler\interface.jl:76
 [65] (::GalacticOptim.var"#160#170"{GalacticOptim.var"#159#169"{OptimizationFunction{true, GalacticOptim.AutoZygote, DiffEqFlux.var"#74#79"{typeof(loss)}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing}, Nothing}})(::Vector{Float32}, ::Vector{Float32})
    @ GalacticOptim C:\Users\Hossein Pourbozorg\.julia\packages\GalacticOptim\bEh06\src\function\zygote.jl:8
 [66] macro expansion
    @ C:\Users\Hossein Pourbozorg\.julia\packages\GalacticOptim\bEh06\src\solve\flux.jl:43 [inlined]
 [67] macro expansion
    @ C:\Users\Hossein Pourbozorg\.julia\packages\GalacticOptim\bEh06\src\solve\solve.jl:35 [inlined]
 [68] __solve(prob::OptimizationProblem{false, OptimizationFunction{false, GalacticOptim.AutoZygote, OptimizationFunction{true, GalacticOptim.AutoZygote, DiffEqFlux.var"#74#79"{typeof(loss)}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing}, GalacticOptim.var"#160#170"{GalacticOptim.var"#159#169"{OptimizationFunction{true, GalacticOptim.AutoZygote, DiffEqFlux.var"#74#79"{typeof(loss)}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing}, Nothing}}, GalacticOptim.var"#163#173"{GalacticOptim.var"#159#169"{OptimizationFunction{true, GalacticOptim.AutoZygote, DiffEqFlux.var"#74#79"{typeof(loss)}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing}, Nothing}}, GalacticOptim.var"#168#178", Nothing, Nothing, Nothing}, Vector{Float32}, SciMLBase.NullParameters, Nothing, Nothing, Nothing, Nothing, Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}}, opt::ADAM, data::Base.Iterators.Cycle{Tuple{GalacticOptim.NullData}}; maxiters::Int64, cb::Function, progress::Bool, save_best::Bool, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ GalacticOptim C:\Users\Hossein Pourbozorg\.julia\packages\GalacticOptim\bEh06\src\solve\flux.jl:41
 [69] #solve#476
    @ C:\Users\Hossein Pourbozorg\.julia\packages\SciMLBase\NwvCY\src\solve.jl:3 [inlined]
 [70] sciml_train(::typeof(loss), ::Vector{Float32}, ::ADAM, ::GalacticOptim.AutoZygote; lower_bounds::Nothing, upper_bounds::Nothing, maxiters::Int64, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ DiffEqFlux C:\Users\Hossein Pourbozorg\.julia\packages\DiffEqFlux\N7blG\src\train.jl:89
in expression starting at C:\Users\Hossein Pourbozorg\Code Projects\Mine\ffjord-report-issues\iss-9.jl:19

In this environment:

(ffjord-report-issues) pkg> status
      Status `C:\Users\Hossein Pourbozorg\Code Projects\Mine\ffjord-report-issues\Project.toml`
  [aae7a2af] DiffEqFlux v1.43.0
  [0c46a032] DifferentialEquations v6.19.0
  [31c24e10] Distributions v0.25.19
  [a75be94c] GalacticOptim v2.0.3

julia> versioninfo()
Julia Version 1.6.1
Commit 6aaedecc44 (2021-04-23 05:59 UTC)
Platform Info:
  OS: Windows (x86_64-w64-mingw32)
  CPU: Intel(R) Core(TM) i7-10750H CPU @ 2.60GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-11.0.1 (ORCJIT, skylake)
@ChrisRackauckas
Copy link
Member

We should just get rid of the mutation in that function:

function jacobian_fn(f, x::AbstractMatrix)
    y, back = Zygote.pullback(f, x)
    z = Zygote.@ignore similar(y)
    Zygote.@ignore fill!(z, zero(eltype(x)))
    out = map(1:size(y, 1)) do i
        Zygote.@ignore z[i, :] .+= one(eltype(x))
        xx = back(z)[1]
    end
    @show size(Array(VectorOfArray(out)))
    return Array(VectorOfArray(out))
 end

But size(Array(VectorOfArray(out))) = (1, 100, 1), so the next stage fails because the sizing is off. Is this example input not sized correctly?

@prbzrg
Copy link
Member Author

prbzrg commented Oct 12, 2021

I think the problem comes from

sensealg = InterpolatingAdjoint(autojacvec=false)

because

sensealg = InterpolatingAdjoint()

works fine.

@ChrisRackauckas
Copy link
Member

Oh interesting. I think it might need to vec on the DiffEqSensitivity side. @frankschae do you have a second open to look at that?

@frankschae
Copy link
Member

Yup, I'll have a look later today.

@frankschae
Copy link
Member

From a quick look in the lines around https://github.com/SciML/DiffEqSensitivity.jl/blob/22b52f82cd8177046ef32adb3baf402983249d61/src/derivative_wrappers.jl#L267

Indeed y is not a vector but a matrix.

typeof(y) = Matrix{Float64}
typeof(p) = Vector{Float32}
typeof(t) = Float32

Wrapping a vec around y in pf.u = y (and also replacing all y by vec(y) in adjointdiffcache) gives however a dimension error:

ERROR: LoadError: DimensionMismatch("matrix A has dimensions (1,1), matrix B has dimensions (199,1)")
Stacktrace:
  [1] _generic_matmatmul!(C::Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float64, 2}}, tA::Char, tB::Char, A::Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float32, 2}}, B::Matrix{Float64}, _add::LinearAlgebra.MulAddMul{true, true, Bool, Bool})
    @ LinearAlgebra /Users/julia/buildbot/worker/package_macos64/build/usr/share/julia/stdlib/v1.6/LinearAlgebra/src/matmul.jl:814
  [2] generic_matmatmul!(C::Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float64, 2}}, tA::Char, tB::Char, A::Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float32, 2}}, B::Matrix{Float64}, _add::LinearAlgebra.MulAddMul{true, true, Bool, Bool})
    @ LinearAlgebra /Users/julia/buildbot/worker/package_macos64/build/usr/share/julia/stdlib/v1.6/LinearAlgebra/src/matmul.jl:802
  [3] mul!
    @ /Users/julia/buildbot/worker/package_macos64/build/usr/share/julia/stdlib/v1.6/LinearAlgebra/src/matmul.jl:302 [inlined]
  [4] mul!
    @ /Users/julia/buildbot/worker/package_macos64/build/usr/share/julia/stdlib/v1.6/LinearAlgebra/src/matmul.jl:275 [inlined]
  [5] *
    @ /Users/julia/buildbot/worker/package_macos64/build/usr/share/julia/stdlib/v1.6/LinearAlgebra/src/matmul.jl:153 [inlined]
  [6] (::Dense{typeof(tanh), Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float32, 2}}, Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float32, 2}}})(x::Matrix{Float64})
    @ Flux ~/.julia/packages/Flux/ZnXxS/src/layers/basic.jl:158
  [7] applychain
    @ ~/.julia/packages/Flux/ZnXxS/src/layers/basic.jl:47 [inlined]
  [8] (::Chain{Tuple{Dense{typeof(tanh), Matrix{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float32, 2}}, Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, DiffEqFlux.var"#59#64"{Bool, Bool, FFJORD{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}, Vector{Float32}, Flux.var"#60#62"{Chain{Tuple{Dense{typeof(tanh), Matrix{Float32}, Vector{Float32}}}}}, FullNormal, Tuple{Float32, Float32}, Tuple{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}}, Base.Iterators.Pairs{Symbol, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Tuple{Symbol}, NamedTuple{(:sensealg,), Tuple{BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}}}}}, Matrix{Float64}}, LinearAlgebra.UniformScaling{Bool}, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, typeof(SciMLBase.DEFAULT_OBSERVED), Nothing}, Float32, Vector{Float64}}, Float32}, Float32, 2}}}}})(x::Matrix{Float64})
    @ Flux ~/.julia/packages/Flux/ZnXxS/src/layers/basic.jl:49
  [9] ffjord(u::Vector{Float64}, p::Vector{ForwardDiff.Dual{ForwardDiff.Tag{DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, 
    @ DiffEqFlux ~/.julia/packages/DiffEqFlux/N7blG/src/ffjord.jl:182
 [10] #59
    @ ~/.julia/packages/DiffEqFlux/N7blG/src/ffjord.jl:194 [inlined]
 [11] ODEFunction
    @ ~/.julia/packages/SciMLBase/NwvCY/src/scimlfunctions.jl:334 [inlined]
 [12] ParamGradientWrapper
    @ ~/.julia/dev/DiffEqSensitivity/src/derivative_wrappers.jl:17 [inlined]
 [13] vector_mode_dual_eval!
    @ ~/.julia/packages/ForwardDiff/XcU3G/src/apiutils.jl:37 [inlined]
 [14] vector_mode_jacobian(f::DiffEqSensitivity.ParamGradientWrapper{ODEFunction{false, 
    @ ForwardDiff ~/.julia/packages/ForwardDiff/XcU3G/src/jacobian.jl:147
 [15] jacobian(f::Function, x::Vector{Float32}, 
    @ ForwardDiff ~/.julia/packages/ForwardDiff/XcU3G/src/jacobian.jl:19
 [17] jacobian
    @ ~/.julia/dev/DiffEqSensitivity/src/derivative_wrappers.jl:135 [inlined]
 [18] _vecjacobian!(dλ::SubArray{Float64, 1, Vector{Float64}, Tuple{UnitRange{Int64}}, true}, 
    @ DiffEqSensitivity ~/.julia/dev/DiffEqSensitivity/src/backsolve_adjoint.jl:36
 [21] ODEFunction
    @ ~/.julia/packages/SciMLBase/NwvCY/src/scimlfunctions.jl:334 [inlined]
 [22] initialize!(integrator::OrdinaryDiffEq.ODEIntegrator{Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), 
    @ OrdinaryDiffEq ~/.julia/packages/OrdinaryDiffEq/Zi9Zh/src/perform_step/low_order_rk_perform_step.jl:623
 [23] __init(prob::ODEProblem{Vector{Float64}, Tuple{Float32, Float32}, true, Vector{Float32}, ODEFunction{true, ...
    @ OrdinaryDiffEq ~/.julia/packages/OrdinaryDiffEq/Zi9Zh/src/solve.jl:456
 [24] #__solve#471
    @ ~/.julia/packages/OrdinaryDiffEq/Zi9Zh/src/solve.jl:4 [inlined]
 [25] #solve_call#42
    @ ~/.julia/packages/DiffEqBase/OPDgm/src/solve.jl:61 [inlined]
 [26] solve_up(prob::ODEProblem{Vector{Float64}, Tuple{Float32, Float32}, true, Vector{Float32}, ....  
    @ DiffEqBase ~/.julia/packages/DiffEqBase/OPDgm/src/solve.jl:87
 [27] #solve#43
    @ ~/.julia/packages/DiffEqBase/OPDgm/src/solve.jl:73 [inlined]
 [28] _adjoint_sensitivities(sol::ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, 
    @ DiffEqSensitivity ~/.julia/dev/DiffEqSensitivity/src/sensitivity_interface.jl:36
 [29] adjoint_sensitivities(::ODESolution{Float64, 3, Vector{Matrix{Float64}}, Nothing, Nothing, ....
    @ DiffEqSensitivity ~/.julia/dev/DiffEqSensitivity/src/sensitivity_interface.jl:6
 [30] (::DiffEqSensitivity.var"#adjoint_sensitivity_backpass#234"{Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, Vector{Float32}, Tuple{}, Colon, NamedTuple{(), Tuple{}}})(Δ::Array{Float64, 3})
    @ DiffEqSensitivity ~/.julia/dev/DiffEqSensitivity/src/concrete_solve.jl:272
 [31] ZBack
    @ ~/.julia/packages/Zygote/Lw5Kf/src/compiler/chainrules.jl:168 [inlined]
 [32] (::Zygote.var"#203#204"{Tuple{NTuple{4, Nothing}, Tuple{Nothing}}, Zygote.ZBack{DiffEqSensitivity.var"#adjoint_sensitivity_backpass#234"{Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, Vector{Float32}, Tuple{}, Colon, NamedTuple{(), Tuple{}}}}})(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/Zygote/Lw5Kf/src/lib/lib.jl:203
 [33] (::Zygote.var"#1734#back#205"{Zygote.var"#203#204"{Tuple{NTuple{4, Nothing}, Tuple{Nothing}}, Zygote.ZBack{DiffEqSensitivity.var"#adjoint_sensitivity_backpass#234"{Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, Tsit5{typeof(OrdinaryDiffEq.trivial_limiter!), typeof(OrdinaryDiffEq.trivial_limiter!)}, BacksolveAdjoint{0, true, Val{:central}, Bool, Bool}, Matrix{Float64}, Vector{Float32}, Tuple{}, Colon, NamedTuple{(), Tuple{}}}}}})(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/ZygoteRules/AIbCs/src/adjoint.jl:67
 [34] Pullback
    @ ~/.julia/packages/DiffEqBase/OPDgm/src/solve.jl:73 [inlined]
 [35] (::typeof(∂(#solve#43)))(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/Zygote/Lw5Kf/src/compiler/interface2.jl:0
 [36] (::Zygote.var"#203#204"{Tuple{NTuple{6, Nothing}, Tuple{Nothing}}, typeof(∂(#solve#43))})(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/Zygote/Lw5Kf/src/lib/lib.jl:203
 [37] (::Zygote.var"#1734#back#205"{Zygote.var"#203#204"{Tuple{NTuple{6, Nothing}, Tuple{Nothing}}, typeof(∂(#solve#43))}})(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/ZygoteRules/AIbCs/src/adjoint.jl:67
 [38] Pullback
    @ ~/.julia/packages/DiffEqBase/OPDgm/src/solve.jl:68 [inlined]
 [39] (::typeof(∂(solve##kw)))(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/Zygote/Lw5Kf/src/compiler/interface2.jl:0
 [40] (::Zygote.var"#203#204"{Tuple{Tuple{Nothing, Nothing, Nothing}, Tuple{Nothing}}, typeof(∂(solve##kw))})(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/Zygote/Lw5Kf/src/lib/lib.jl:203
 [41] (::Zygote.var"#1734#back#205"{Zygote.var"#203#204"{Tuple{Tuple{Nothing, Nothing, Nothing}, Tuple{Nothing}}, typeof(∂(solve##kw))}})(Δ::Array{Float64, 3})
    @ Zygote ~/.julia/packages/ZygoteRules/AIbCs/src/adjoint.jl:67
 [42] Pullback
    @ ~/.julia/packages/DiffEqFlux/N7blG/src/ffjord.jl:208 [inlined]
 [43] (::typeof(∂(#_#58)))(Δ::Tuple{Matrix{Float64}, Nothing, Nothing})
    @ Zygote ~/.julia/packages/Zygote/Lw5Kf/src/compiler/interface2.jl:0
 [44] Pullback
    @ ~/.julia/packages/DiffEqFlux/N7blG/src/ffjord.jl:192 [inlined]

Is that the solution you meant, @ChrisRackauckas? And is:

function ffjord(u, p, t, re, e;

the definition of the ODE function that needs to be differentiated? (Haven't looked at the ffjord implementation so far)

@ChrisRackauckas
Copy link
Member

Yeah that's what I meant. Odd.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants