From 28dd0f3ac1675c31f732d0c0a7791b3305107c28 Mon Sep 17 00:00:00 2001 From: Mikkel Lykkegaard Date: Tue, 23 Jan 2024 17:17:18 +0000 Subject: [PATCH] Trip initilialisation of SBR of unbias=True, since it's incompatible --- pysindy/optimizers/sbr.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/pysindy/optimizers/sbr.py b/pysindy/optimizers/sbr.py index 7783bf872..35cc2be3b 100644 --- a/pysindy/optimizers/sbr.py +++ b/pysindy/optimizers/sbr.py @@ -81,9 +81,15 @@ def __init__( num_warmup: int = 1000, num_samples: int = 5000, mcmc_kwargs: Optional[dict] = None, + unbias: bool = False, **kwargs, ): - super().__init__(**kwargs) + + if unbias: + raise ValueError("SBR is incompatible with unbiasing. Set unbias=False") + + super().__init__(unbias=unbias, **kwargs) + # set the hyperparameters self.sparsity_coef_tau0 = sparsity_coef_tau0 self.slab_shape_nu = slab_shape_nu