Possible fix for #1112

Ensures that the temporary file created by PLY gets written to a temporary location, not the Astropy source tree.