286a864220a00732d382a75051e11877acf13c3f,deeppavlov/core/models/keras_model.py,KerasModel,load,#KerasModel#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#,141
Before Change
model with loaded weights and network parameters from files
but compiled with given learning parameters
if self.ser_path.is_dir():
opt_path = "{}/{}_opt.json".format(self.ser_path, self._ser_file)
weights_path = "{}/{}.h5".format(self.ser_path, self._ser_file)
else:
opt_path = "{}_opt.json".format(self.ser_path)
weights_path = "{}.h5".format(self.ser_path)
if Path(opt_path).exists() and Path(weights_path).exists():
print("___Initializing model from saved___"
"\nModel weights file is %s.h5"
After Change
but compiled with given learning parameters
if self.load_path:
if isinstance(self.load_path, Path) and not self.load_path.parent.is_dir():
raise ConfigError("Provided save path is incorrect!")
opt_path = Path("{}_opt.json".format(str(self.load_path.resolve())))
weights_path = Path("{}.h5".format(str(self.load_path.resolve())))
if opt_path.exists() and weights_path.exists():
print("___Initializing model from saved___"
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 14
Instances
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: 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: save
Project Name: deepmipt/DeepPavlov
Commit Name: 5390c650dadd1e86b6c43543ac0ed384e8ebfc4d
Time: 2018-05-15
Author: yoptar@gmail.com
File Name: deeppavlov/core/models/keras_model.py
Class Name: KerasModel
Method Name: save