Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions supervised/model_framework.py
Original file line number Diff line number Diff line change
Expand Up @@ -721,6 +721,9 @@ def load(results_path, model_subpath, lazy_load=True):
for learner_desc, learner_subpath in zip(
json_desc.get("learners"), json_desc.get("saved")
):
# Normalize path separators for cross-platform compatibility
# (models trained on Windows may have backslashes in paths)
learner_subpath = learner_subpath.replace("\\", "/")
learner_path = os.path.join(results_path, learner_subpath)
l = AlgorithmFactory.load(learner_desc, learner_path, lazy_load)
mf.learners += [l]
Expand Down