Fixed naming issue with array ranks greater than 1
Fixed illegal characters in output path