processing files sequentially instead of parallel to reduce memory usage