trim num_partitions file content from spaces and newline