COMP: Ported diffusion image writer

And fixed many mini apps and test
Merge branch 'bug-18353-port-diffusion-readers-writers'