fixed output subfolders and output file names