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

Matrix Variate Bijectors - Lower/Uppertriangular transforms #215

Open
paschermayr opened this issue Mar 30, 2022 · 0 comments
Open

Matrix Variate Bijectors - Lower/Uppertriangular transforms #215

paschermayr opened this issue Mar 30, 2022 · 0 comments

Comments

@paschermayr
Copy link

paschermayr commented Mar 30, 2022

Dear all,

I wanted to ask why a PDBijector transforms the input to a lowertriangular matrix while a CorrBijector transforms the input into a uppertriangular matrix. It seems like most AD libraries evaluate gradients based on a upper triangular matrix, hence I have troubles with the PDBijector:

using Bijectors
mat = [1. .3 ; .3 1.]
bij_1 = Bijectors.PDBijector()
bij_2 = Bijectors.CorrBijector()

mat_1_transformed = bij_1(mat)
#=
2×2 Matrix{Float64}:
 0.0   0.0
 0.3  -0.0471553
=#
mat_2_transformed = bij_2(mat)
#=
2×2 Matrix{Float64}:
 0.0  0.30952
 0.0  0.0
=#

Is there any chance that PDBijector might return a uppertriangular matrix too?

Best regards,
Patrick

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

1 participant