Actions
Feature #1084
closedCheck validity of IS and DS elements when converting from DICOM to JSON
Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Library and Apps
Target version:
-
Start date:
2023-08-16
Due date:
% Done:
100%
Estimated time:
2:00 h
Module:
dcmdata
Operating System:
Compiler:
Description
When converting DICOM "Integer String" and "Decimal String" values to JSON numbers, some modifications are performed that convert numbers that are valid in DICOM but not in JSON into valid JSON numbers.
Currently, the code does not check if the DICOM string is actually a valid number according to DICOM rules, and if the DICOM string is illegal, the JSON output may be syntactically invalid.
It would be desirable to check the VR using the existing dcmdata VR checker, and either print a warning or return an error if the number to be converted is invalid.
The VR checker could be used for other DICOM VRs as well, but IS and DS are specifically important because invalid values may cause the JSON output to be syntactically invalid.
Actions