When trying to convert an Optovue .OCT file to dicom, the _validate method of the BOCT class raised a StringError instead of an UnicodeError when parsing the file header structure.
I corrected that and then got another error in the write_opt_dicom function : when assigning the value to input_datetime, meta.series_info.acquisition_date was already a datetime.datetime object and not a string.
I changed that as well and then the conversion to dicom was successful.
Steps to reproduce : convert Optovue .OCT to dicom with create_dicom_from_oct.
I didn't look into it further but since this is such an easy fix I thought maybe someone would know why this happened.
The dicom writer is relatively new and has not been tested much for Optovue data, so it's quite possible this is a bug that just hasn't been spotted yet. Feel free to propose a PR to fix this!
Hi,
When trying to convert an Optovue .OCT file to dicom, the _validate method of the BOCT class raised a StringError instead of an UnicodeError when parsing the file header structure. I corrected that and then got another error in the write_opt_dicom function : when assigning the value to input_datetime, meta.series_info.acquisition_date was already a datetime.datetime object and not a string. I changed that as well and then the conversion to dicom was successful.
Steps to reproduce : convert Optovue .OCT to dicom with create_dicom_from_oct.
I didn't look into it further but since this is such an easy fix I thought maybe someone would know why this happened.