def load_abbr(abbr_file=ABBREVIATION_FILE):
    """
    Load the abbr2long from file
    """
    abbr2long = dict()
    with open(abbr_file) as f:
        lines = f.read().split('\n')
        for line in lines:
            m = re.match(r'(\w+)\t(.+)', line)
            if m:
                abbr2long[m.group(1)] = m.group(2)
    return abbr2long
def load_abbr ( abbr_file = ABBREVIATION_FILE ) : abbr2long = dict ( ) with open ( abbr_file ) as f : lines = f . read ( ) . split ( '\n' ) for line in lines : m = re . match ( r'(\w+)\t(.+)' , line ) if m : abbr2long [ m . group ( 1 ) ] = m . group ( 2 ) return abbr2long
Load the abbr2long from file