90c2e0df5127c85a780fd71c20e833002fb0608a,TextRecognitionDataGenerator/run.py,,load_dict,#Any#,267

Before Change



    lang_dict = []
    with open(os.path.join("dicts", lang + ".txt"), "r", encoding="utf8", errors="ignore") as d:
        lang_dict = d.readlines()
    return lang_dict

def load_fonts(lang):
    

After Change



    lang_dict = []
    with open(os.path.join("dicts", lang + ".txt"), "r", encoding="utf8", errors="ignore") as d:
        lang_dict = [l for l in d.read().splitlines() if len(l) > 0]
    return lang_dict

def load_fonts(lang):
    
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: Belval/TextRecognitionDataGenerator
Commit Name: 90c2e0df5127c85a780fd71c20e833002fb0608a
Time: 2019-06-14
Author: edouard@belval.org
File Name: TextRecognitionDataGenerator/run.py
Class Name:
Method Name: load_dict


Project Name: deepmipt/DeepPavlov
Commit Name: e6d93849bcf1728bfededc7566fd9820bd9a1304
Time: 2017-12-11
Author: yoptar@gmail.com
File Name: speller/models/static_dictionary.py
Class Name: StaticDictionary
Method Name: _get_source


Project Name: hanxiao/bert-as-service
Commit Name: dbc41cb728a33cebdaeafff5d494fa7bb4ebc382
Time: 2018-11-11
Author: hanhxiao@tencent.com
File Name: client_example.py
Class Name:
Method Name: