Skip to content

Commit

Permalink
Fix for some type instabilities (#354)
Browse files Browse the repository at this point in the history
* improvement to type-stability of `_logabsdetjac_dist` for batched
multivariate distributions

* bumped patch version
  • Loading branch information
torfjelde authored Nov 30, 2024
1 parent d342371 commit 55501ae
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "Bijectors"
uuid = "76274a88-744f-5084-9051-94815aaf08c4"
version = "0.15"
version = "0.15.1"

[deps]
ArgCheck = "dce04be8-c92d-5529-be00-80e4d2c0e197"
Expand Down
2 changes: 1 addition & 1 deletion src/Bijectors.jl
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ function _logabsdetjac_dist(d::MultivariateDistribution, x::AbstractVector)
return logabsdetjac(bijector(d), x)
end
function _logabsdetjac_dist(d::MultivariateDistribution, x::AbstractMatrix)
return logabsdetjac.((bijector(d),), eachcol(x))
return map(Base.Fix1(logabsdetjac, bijector(d)), eachcol(x))
end

_logabsdetjac_dist(d::MatrixDistribution, x::AbstractMatrix) = logabsdetjac(bijector(d), x)
Expand Down

2 comments on commit 55501ae

@torfjelde
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/120439

Tip: Release Notes

Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.

@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.15.1 -m "<description of version>" 55501ae8e6fbb414b743fdf10be34f3275616464
git push origin v0.15.1

Please sign in to comment.