Skip to content
This repository has been archived by the owner on Jul 8, 2020. It is now read-only.

Request help on AIMConverter.exe #2

Open
glhfgg1024 opened this issue Jan 10, 2018 · 5 comments
Open

Request help on AIMConverter.exe #2

glhfgg1024 opened this issue Jan 10, 2018 · 5 comments

Comments

@glhfgg1024
Copy link

Hi Dear Sir/Madam,

Thanks for sharing this valuable toolkit!
I have a problem, I want to convert the AIM XML files to DICOM-RT file.
I use the following command:

C:\annotation-and-image-markup-master\AIMToolkit_v4.0.0_rv44\source\AIMLib\Release\x64>AIMConverter.exe -i AIM -o SR AMC-003.xml AMC-003

But there are some errors as follows:

Error: Error writing annotation(s) to file "AMC-003":
Annotation Collection Validation Errors:
Annotation Collection Unique Identifier
II value is not a valid UID
UID must constist of digits and periods(.) only

Usage:
AIMConverter.exe -i[nput] AIM|SR|CDA -o[utput] AIM|SR|CDA input_file output_file

If convenient, could you please give some advice? Thanks a lot!

@vkleper
Copy link

vkleper commented Jan 11, 2018 via email

@glhfgg1024
Copy link
Author

Hi, @vkleper, thanks a lot for your kind comments and suggestions!

Yeah, after debugging the code, I've found that the UID in AIM-003.xml is as follows:

<uniqueIdentifier root="hnmh13izcz8kr4gxa1efkiaygscgfv77jz79mvoy"></uniqueIdentifier>

But in the header of this xml, it shows:

<ImageAnnotationCollection aimVersion="AIMv4_0" xmlns="gme://caCORE.caCORE/4.4/edu.northwestern.radiology.AIM" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="gme://caCORE.caCORE/4.4/edu.northwestern.radiology.AIM AIM_v4_rv44_XML.xsd">

So from the header, it seems the xml is generated from AIM 4.1.0 version. But when I tried to convert the AIM-003.xml to AIM-003.dcm, it would fail.

When I commented the validation code in "ModelValidator.cpp",

bool ModelValidator::isValid(const iso_21090::II& ii, bool allowDefaults /*= false*/)
{
    //RETURN_IF_UID_NOT_VALID(ii.toString(), "II");
    return true;
}

Then other errors occured:

(base) C:\annotation-and-image-markup-master\AIMToolkit_v4.1.0_rv44\source\AIMLib\Release\x64>AIMConverter.exe -i XML -o SR ./AMC-003.xml AMC-003.dcm
Error: Error writing annotation(s) to file "AMC-003.dcm":
Annotation Collection Validation Errors:
Person is invalid
Birth Date is invalid
Month value must be between 1 and 12

So, I'm not sure if the AMC-003.xml was generated from AIM 4.1.0.

@vkleper
Copy link

vkleper commented Feb 8, 2018 via email

@glhfgg1024
Copy link
Author

Hi @vkleper , thanks a lot for your kind reply and suggestions!

I'm trying to parse https://wiki.cancerimagingarchive.net/download/attachments/28672347/AIM_files.zip?version=1&modificationDate=1512415990689&api=v2 file.

Yeah, I also found that the data creator may use other version of AIMConverter to generate their files.
Thanks a lot for your kind suggestions!

@constiDisch
Copy link

Hi @glhfgg1024 ,
I am running into the same problem, when reading the (updated?) data from https://wiki.cancerimagingarchive.net/display/Public/NSCLC+Radiogenomics . Could you give me a hint how you solved the problem?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants