@staticmethod<EOL><INDENT>def extract_log(log_path, dict_type=dict):<DEDENT>
log_path = (log_path if os.path.isfile(log_path)<EOL>else os.path.join(os.getcwd(), log_path))<EOL>with open(log_path,'<STR_LIT:r>') as log:<EOL><INDENT>splits = (line.split() for line in log)<EOL>uzipped = ((int(split[<NUM_LIT:0>]), json.loads("<STR_LIT:U+0020>".join(split[<NUM_LIT:1>:]))) for split in splits)<EOL>szipped = [(i, dict((str(k),v) for (k,v) in d.items())) for (i,d) in uzipped]<EOL><DEDENT>return dict_type(szipped)<EOL>
Parses the log file generated by a launcher and returns
dictionary with tid keys and specification values.

Ordering can be maintained by setting dict_type to the
appropriate constructor (i.e. OrderedDict). Keys are converted
from unicode to strings for kwarg use.