Got rid of a redundant file seek. Method seek of io.TextIOWrapper most time consuming according to CPU profiler.