#NEWLINE# def get_info_dict( info_line ) : #NEWLINE# #INDENT# 'Parse a info field of a variant\n        \n        Make a dictionary from the info field of a vcf variant.\n        Keys are the info keys and values are the raw strings from the vcf\n        \n        Args:\n            info_line (str): The info field of a vcf variant\n        Returns:\n            info_dict (dict): A INFO dictionary\n    ' #NEWLINE# variant_info = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for raw_info in info_line . split ( ';' ) : #NEWLINE# #INDENT# splitted_info = raw_info . split ( '=' ) #NEWLINE# if ( len ( splitted_info ) == 2 ) : #NEWLINE# #INDENT# variant_info [ splitted_info [ 0 ] ] = splitted_info [ 1 ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# variant_info [ splitted_info [ 0 ] ] = [ ] #NEWLINE# #UNINDENT# #UNINDENT# return variant_info