0a01df9bdc0bd142eff95a1c878947047194d617,deeppavlov/core/commands/train.py,,train_model_from_config,#Any#,72

Before Change


    data_path = expand_path(reader_config.get("data_path", ""))
    kwargs = reader_config.copy()
    if "name" in kwargs: del kwargs["name"]
    if "data_path" in kwargs: del kwargs["data_path"]
    data = reader.read(data_path, **kwargs)

    iterator_config = config["dataset_iterator"]
    dataset: BasicDatasetIterator = from_params(iterator_config, data=data)

After Change


    reader_config = config["dataset_reader"]
    reader = get_model(reader_config["name"])()
    data_path = expand_path(reader_config.get("data_path", ""))
    kwargs = {k: v for k, v in reader_config.items() if k not in ["name", "data_path"]}
    data = reader.read(data_path, **kwargs)

    iterator_config = config["dataset_iterator"]
    dataset: BasicDatasetIterator = from_params(iterator_config, data=data)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: deepmipt/DeepPavlov
Commit Name: 0a01df9bdc0bd142eff95a1c878947047194d617
Time: 2018-03-16
Author: ol.gure@gmail.com
File Name: deeppavlov/core/commands/train.py
Class Name:
Method Name: train_model_from_config


Project Name: wkentaro/labelme
Commit Name: 7ad8d5c5cf89269d191117c4dd41ce205bc66c8c
Time: 2019-05-15
Author: www.kentaro.wada@gmail.com
File Name: labelme/widgets/label_dialog.py
Class Name: LabelDialog
Method Name: resetFlags


Project Name: deepmipt/DeepPavlov
Commit Name: 3e6d5a72b03f7a17bdaf5967e337db077c89df41
Time: 2018-01-22
Author: arkhipov@yahoo.com
File Name: deeppavlov/models/ner/ner.py
Class Name: NER
Method Name: __init__