Oliver Schulz
Oliver Schulz
CC @mmikhasenko
> What would this look like inn BAT? > ```p(n, a | mu,gamma) = Pois( n | mu*s + gamma*b) Pois( a | gamma*d )``` In Julia/BAT, it would look...
Thanks for the nice write-up, @niklasschmitz! In addition to Zygote, one can of course also use ForwardDiff (faster with very few parameters due to lower overhead), Enzyme (though it crashes...
> pyhf is free via PyCall, for example Oh, sure! Might still be very useful to have a Julia implementation longer-term, though, for deeper integration, to use Julia autodiff, and...
But you're right, we can use `pyhf` right now via PyCall, would be good to put and example for `pyhf` + BAT.jl together. Have to think how to handle priors,...
Does pyhf export an API for it's autodiff-pullback?
Neat! We can wrap that in a `ChainRulesCore.rrule`.
It'll basically just be something like this: ```julia using DensityInterface, ChainRulesCore, PyCall const jax = pyimport("jax") struct PyHfLikelihood{LT} log_likelihood::LT end DensityInterface.logdensityof(d::PyHfLikelihood, x::AbstractVector{
@Moelf provided a nice initial example in #345.
And we should make life easier on the user by looking into the pyhf model to get the order of variables, so things won't go badly if they are in...