Skip to content

Commit

Permalink
fixed an issue concerncing the dependency between the base model and cdc
Browse files Browse the repository at this point in the history
  • Loading branch information
lyna1404 committed Aug 14, 2024
1 parent fdcb264 commit a65d7f3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions MED3pa/models/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"""
import pickle
from io import BytesIO
import copy

from .abstract_models import Model

Expand Down Expand Up @@ -72,10 +73,10 @@ def clone_base_model(cls) -> Model:
cloned_model.model = pickle.load(buffer)
cloned_model.model_class = cls.__baseModel.model_class
cloned_model.pickled_model = True
cloned_model.params = cls.__baseModel.params
cloned_model.params = copy.deepcopy(cls.__baseModel.params)
else:
for attribute, value in vars(cls.__baseModel).items():
setattr(cloned_model, attribute, value)
setattr(cloned_model, attribute, copy.deepcopy(value))

return cloned_model

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

setup(
name="MED3pa",
version="0.1.24",
version="0.1.25",
author="MEDomics consortium",
author_email="medomics.info@gmail.com",
description="Python Open-source package for ensuring robust and reliable ML models deployments",
Expand Down

0 comments on commit a65d7f3

Please sign in to comment.