I want to implement a function of converting images to DICOM. According to the implementation in write.go, I failed to complete it. I hope to get help