clean up write raster