save image when scan is finished in multi-sample workflow