From f050a97c7a1e2a7fd17aaa3dd2f683f8f1bd08f8 Mon Sep 17 00:00:00 2001 From: Jonathan Conder Date: Thu, 20 Oct 2022 14:18:00 +1300 Subject: [PATCH] Avoid calling should_pickle on models --- umap/parametric_umap.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/umap/parametric_umap.py b/umap/parametric_umap.py index 95d1bced..51674dcf 100644 --- a/umap/parametric_umap.py +++ b/umap/parametric_umap.py @@ -483,7 +483,7 @@ def __getstate__(self): return dict( (k, v) for (k, v) in self.__dict__.items() - if should_pickle(k, v) and k not in ("optimizer", "encoder", "decoder", "parametric_model") + if k not in ("optimizer", "encoder", "decoder", "parametric_model") and should_pickle(k, v) ) def save(self, save_location, verbose=True):