transformation seperated for binary and dicom