Skip to content

Commit

Permalink
Simplify f for Reparametrizer
Browse files Browse the repository at this point in the history
  • Loading branch information
tkf committed Jul 27, 2018
1 parent 09f8294 commit 9df192d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/examples/reparametrization.jl
Expand Up @@ -77,7 +77,7 @@ function f(y::TY, rp::Reparametrizer, t) where {TY <: SVector}

# (g'(y))⁻¹ = (g⁻¹(x))' = (tanh(M⁻¹ (x - shift)))' = tanh' M⁻¹
dy = (1 .- y .* y) .* (rp.invM * dx)
dy = SVector(promote(dy...)...) # TODO: don't
dy = SVector(dy...) # TODO: don't
@assert ! badeltype(dy)
return dy
# return dy :: TY
Expand Down

0 comments on commit 9df192d

Please sign in to comment.