LogExpFunctions.jl icon indicating copy to clipboard operation
LogExpFunctions.jl copied to clipboard

Add "a" parameter to softplus() #83

Open DominiqueMakowski opened this issue 1 year ago • 3 comments

Following up the issues related to an exp link-function (https://github.com/TuringLang/Turing.jl/issues/2310), it reinforced the idea that a softplus link could actually be a good alternative. However, I feel like implementing its generalized version (#83) would be key (useful when modelling small parameters), so here my shot at it.

image

DominiqueMakowski avatar Sep 03 '24 07:09 DominiqueMakowski

Add support for InverseFunctions / ChangesOfVariables

Can you clarify?

DominiqueMakowski avatar Sep 14 '24 16:09 DominiqueMakowski

Kind bump

DominiqueMakowski avatar Sep 25 '24 15:09 DominiqueMakowski

Sorry, I missed your previous comment.

Add support for InverseFunctions / ChangesOfVariables

Since this PR adds new functions, we should also add definitions of InverseFunctions.inverse to https://github.com/JuliaStats/LogExpFunctions.jl/blob/289114f535827c612ce10c01b8dec9d3a55e4d15/ext/LogExpFunctionsInverseFunctionsExt.jl and definitions of ChangesOfVariables.with_logabsdet_jacobian to https://github.com/JuliaStats/LogExpFunctions.jl/blob/289114f535827c612ce10c01b8dec9d3a55e4d15/ext/LogExpFunctionsChangesOfVariablesExt.jl. Additionally, we could add definitions of ChainRulesCore.frule and ChainRulesCore.rrule - but in principle AD should "just work" since all other involved functions are known to ChainRules.

devmotion avatar Sep 25 '24 23:09 devmotion

I am not sure how to specify the ChangesofVariables one 🤔

DominiqueMakowski avatar Sep 27 '24 08:09 DominiqueMakowski

Kind bump

DominiqueMakowski avatar Oct 26 '24 08:10 DominiqueMakowski

Since there is no preexisting ChangesOfVariables.with_logabsdet_jacobian for softplus I'm really not sure what to write there

DominiqueMakowski avatar Dec 03 '24 08:12 DominiqueMakowski