yzhao062/pyod

Cannot save AutoEncoder

Open

#256 ouverte le 6 déc. 2020

Voir sur GitHub
 (6 commentaires) (1 réaction) (1 assigné)Python (1 308 forks)batch import
buggood first issuehelp wanted

Métriques du dépôt

Stars
 (7 762 stars)
Métriques de merge PR
 (Merge moyen 4j 17h) (14 PRs mergées en 30 j)

Description

The official instructions say to use joblib for pickling PyOD models.

This fails for AutoEncoders, or any other TensorFlow-backed model as far as I can tell. The error is:

>>> dump(model, 'model.joblib')
...
TypeError: can't pickle _thread.RLock objects

Note that it's not sufficient to save the underlying Keras Sequential model, since I need the methods & variables of BaseDetector (like .decision_scores_ or .decision_function().

Guide contributeur