Skip to content

Commit

Permalink
fix from_config
Browse files Browse the repository at this point in the history
  • Loading branch information
king-menin committed Jan 19, 2019
1 parent 040c9f2 commit 731d39b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/train/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,10 +195,10 @@ def save_config(self, path):
json.dump(self.config, file)

@classmethod
def from_config(cls, path):
def from_config(cls, path, for_train=True):
with open(path, "r") as file:
config = json.load(file)
data = BertNerData.from_config(config["data"])
data = BertNerData.from_config(config["data"], for_train)
name = config["model"]["name"]
# TODO: release all models (now only for BertBiLSTMNCRF)
if name not in released_models:
Expand Down

0 comments on commit 731d39b

Please sign in to comment.