Skip to content

Commit

Permalink
blacken
Browse files Browse the repository at this point in the history
  • Loading branch information
matteobachetti committed Oct 1, 2023
1 parent 5245470 commit 5324211
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions stingray/modeling/gpmodeling.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,7 @@
tfp_available = False


__all__ = ["get_kernel", "get_mean", "get_prior",
"get_log_likelihood", "GPResult", "get_gp_params"]
__all__ = ["get_kernel", "get_mean", "get_prior", "get_log_likelihood", "GPResult", "get_gp_params"]


def get_kernel(kernel_type, kernel_params):
Expand Down Expand Up @@ -575,8 +574,7 @@ def __init__(self, lc: Lightcurve) -> None:
self.counts = lc.counts
self.result = None

def sample(self, prior_model=None, likelihood_model=None, max_samples=1e4,
num_live_points=500):
def sample(self, prior_model=None, likelihood_model=None, max_samples=1e4, num_live_points=500):
"""
Makes a Jaxns nested sampler over the Gaussian Process, given the
prior and likelihood model
Expand Down Expand Up @@ -619,7 +617,9 @@ def sample(self, prior_model=None, likelihood_model=None, max_samples=1e4,
nsmodel = Model(prior_model=self.prior_model, log_likelihood=self.log_likelihood_model)
nsmodel.sanity_check(random.PRNGKey(10), S=100)

self.exact_ns = ExactNestedSampler(nsmodel, num_live_points=num_live_points, max_samples=max_samples)
self.exact_ns = ExactNestedSampler(

Check warning on line 620 in stingray/modeling/gpmodeling.py

View check run for this annotation

Codecov / codecov/patch

stingray/modeling/gpmodeling.py#L620

Added line #L620 was not covered by tests
nsmodel, num_live_points=num_live_points, max_samples=max_samples
)

termination_reason, state = self.exact_ns(
random.PRNGKey(42), term_cond=TerminationCondition(live_evidence_frac=1e-4)
Expand Down

0 comments on commit 5324211

Please sign in to comment.