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

Fix reversed include_logdet bug #82

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions jax_cosmo/likelihood.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This module implements a few likelihoods useful
# This module implements a few useful likelihoods
import jax.numpy as np
import jax.scipy as sp

Expand Down Expand Up @@ -51,7 +51,7 @@ def gaussian_log_likelihood(data, mu, C, include_logdet=True, inverse_method="in
raise NotImplementedError
rT_Cinv_r = r.dot(y)

if include_logdet:
if not include_logdet:
return -0.5 * rT_Cinv_r
else:
if sparse.is_sparse(C):
Expand Down