how to match 'secondary' dicoms?

22 views
Skip to first unread message

Daniel Drucker

unread,
Sep 24, 2021, 10:18:18 AM9/24/21
to xnat_discussion
I want to write a plugin which acts on 'secondary' dicoms:

Untitled.png

This is what I tried:

"contexts": [
"xnat:imageScanData"
],
"external-inputs": [
{
"name": "scan",
"label": null,
"description": "Input scan",
"type": "Scan",
"matcher": "'secondary' in @.resources[*].label",
"default-value": null,
"required": true,
"replacement-key": null,
"sensitive": null,
"provides-value-for-command-input": null,
"provides-files-for-command-mount": null,
"via-setup-command": null,
"user-settable": null,
"load-children": true
}
],
"derived-inputs": [
{
"name": "scan-dicoms",
"label": null,
"description": "The dicom resource on the scan",
"type": "Resource",
"matcher": "@.label == 'DICOM'",
"default-value": null,
"required": true,
"replacement-key": null,
"sensitive": null,
"provides-value-for-command-input": null,
"provides-files-for-command-mount": "dicom-in",
"user-settable": null,
"load-children": true,
"derived-from-wrapper-input": "scan",
"derived-from-xnat-object-property": null,
"via-setup-command": null,
"multiple": false,
"parser": null
}


But I get:

"Unable to resolve for first scan: bulk launch likely to throw exception for this scan (and possibly others, though others may launch without issue)."


What did I do wrong?

Daniel

Moore, Charlie

unread,
Sep 24, 2021, 10:21:44 AM9/24/21
to xnat_di...@googlegroups.com
Hi Daniel,

In your derived-inputs, try changing the matcher to secondary instead of DICOM as well. That "label" field is I believe the label of the resource, which is going to be "secondary" instead of "DICOM".

Thanks,
Charlie

From: xnat_di...@googlegroups.com <xnat_di...@googlegroups.com> on behalf of Daniel Drucker <ddru...@mclean.harvard.edu>
Sent: Friday, September 24, 2021 9:18 AM
To: xnat_discussion <xnat_di...@googlegroups.com>
Subject: [XNAT Discussion] how to match 'secondary' dicoms?
 

* External Email - Caution *

--
You received this message because you are subscribed to the Google Groups "xnat_discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xnat_discussi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xnat_discussion/d8748a13-b7f3-44a5-b8bf-3ed1880ddc30n%40googlegroups.com.

 


The materials in this message are private and may contain Protected Healthcare Information or other information of a sensitive nature. If you are not the intended recipient, be advised that any unauthorized use, disclosure, copying or the taking of any action in reliance on the contents of this information is strictly prohibited. If you have received this email in error, please immediately notify the sender via telephone or return mail.

Daniel Drucker

unread,
Sep 24, 2021, 10:24:39 AM9/24/21
to xnat_discussion
Aha, that worked. Thanks.
Reply all
Reply to author
Forward
0 new messages