This is an efficient code for converting dicom to image Dicom_to_image(path,WW,WL) Parameters: path: location to the dcm file ww: window width wl:window level returns image: array like