Small performance improvement

Create less strings when writing out values partitioned by paths