PSD: simplifying code in readimage to handle _filepath and regular mem-friendly formats