diff --git a/src/grelu/lightning/metrics.py b/src/grelu/lightning/metrics.py index 4ab29d9..82e8904 100644 --- a/src/grelu/lightning/metrics.py +++ b/src/grelu/lightning/metrics.py @@ -144,3 +144,6 @@ def compute(self) -> torch.Tensor: return output.mean() else: return output + + def reset(self) -> None: + self.pearson.reset() diff --git a/tests/test_models.py b/tests/test_models.py index 0590af7..2b4c546 100644 --- a/tests/test_models.py +++ b/tests/test_models.py @@ -12,17 +12,16 @@ EnformerModel, EnformerPretrainedModel, ) +from grelu.resources import DEFAULT_WANDB_HOST from grelu.sequence.format import convert_input_type inputs = convert_input_type(["A" * 128], "one_hot") try: - wandb.login(host="https://genentech.wandb.io", anonymous="never", timeout=0) + wandb.login(host=DEFAULT_WANDB_HOST, anonymous="never", timeout=0) except wandb.errors.UsageError: # login anonymously if not logged in already - wandb.login( - host="https://genentech.wandb.io", relogin=True, anonymous="must", timeout=0 - ) + wandb.login(host=DEFAULT_WANDB_HOST, relogin=True, anonymous="must", timeout=0) # Test a fully convolutional model with residual connections and autocropping