f9540d6da262c88cd4dfa2c3d9e8c2e570ea2f11,mushroom_rl/algorithms/agent.py,Agent,load,#Any#Any#,91
Before Change
if not isinstance(path, str):
raise ValueError("path has to be of type string")
if not Path(path).is_dir():
raise NotADirectoryError("Path to load agent is not valid")
agent_type, save_attributes = cls._load_pickle(
PurePath(path, "agent.config")).values()
agent = agent_type.__new__(agent_type)
After Change
att_val = load_method(zip_file, file_name)
setattr(agent, att, att_val)
else:
print("att", att, "named", file_name, "not in zip")
setattr(agent, att, None)
agent._post_load()
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: AIRLab-POLIMI/mushroom
Commit Name: f9540d6da262c88cd4dfa2c3d9e8c2e570ea2f11
Time: 2020-04-21
Author: boris.ilpossente@hotmail.it
File Name: mushroom_rl/algorithms/agent.py
Class Name: Agent
Method Name: load
Project Name: deepmipt/DeepPavlov
Commit Name: 286a864220a00732d382a75051e11877acf13c3f
Time: 2018-01-24
Author: ol.gure@gmail.com
File Name: deeppavlov/core/models/keras_model.py
Class Name: KerasModel
Method Name: load
Project Name: theislab/scanpy
Commit Name: d603299e387628f3878ff0b783698494f87c602c
Time: 2019-03-29
Author: ivirshup@gmail.com
File Name: scanpy/datasets/_expression_atlas.py
Class Name:
Method Name: expression_atlas