Difference between revisions of "CTSC IGT, BWH"
Line 125: | Line 125: | ||
'''2.b Query the server to see what subjects have been created:''' | '''2.b Query the server to see what subjects have been created:''' | ||
− | XNATRestClient. | + | XNATRestClient -host $XNE_Svr -user_session $JSessionID -m GET -remote /REST/projects/$ProjectID/subjects |
+ | |||
+ | '''2.c Create experiments (collections of image data) you'd like to have for each subject''' | ||
+ | |||
+ | XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/$SubjectID/experiments/MRExperiment?xnat:mrSessionData/date=01/02/09" | ||
+ | XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/$SubjectID/experiments/CTExperiment1?xnat:ctSessionData/date=01/02/09" | ||
+ | XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/$SubjectID/experiments/PETExperiment1?xnat:cpetSessionData/date=01/02/09" | ||
<br> | <br> |
Revision as of 17:44, 17 August 2009
Home < CTSC IGT, BWHBack to CTSC Imaging Informatics Initiative
Contents
Mission
Mark Anderson at Surgical Planning and Channing labs currently manages data for many investigators, pulling data from PACS into the research environment. There is interest in setting up a parallel channel by which the data are also enrolled into an XNAT database and accessed from client, and comparing its ease of use with the existing infrastucture. To explore XNAT as a possible long-term informatics solution for the NCIGT project, Mark will be uploading retrospective data for a number of NCIGT efforts (and PIs):
- NCIGT_Brain_Function (SS/AG)
- Key Investigators:
- Brief Description:
- NCIGT_Tumor_Resection (HK/AG)
- Key Investigators:
- Brief Description:
- NCIGT_Prostate (HE/CT)
- Key Investigators:
- Brief Description:
- NCIGT_Prostate_Fully_Segmented (HE/CT)
- Key Investigators:
- Brief Description:
- NCIGT_Brain_Biopsy (FT)
- Key Investigators:
- Brief Description:
Use-Case Goals
Step 1. Data Management
- Anonymize, apply DICOM metadata and upload retrospective datasets; confirm appropriate organization and naming scheme via web GUI.
Step 2. Query & Retrieval
- Make specific queries using XNAT web services,
- Download data conforming to specific naming convention and directory structure, using XNAT web services
Each effort listed above will have different requirements for being able to query, retrieve and use data collections. Brief description of how retrospective data will be used within the NCIGT is described below:
- NCIGT_Brain_Function:
- NCIGT_Tumor_Resection:
- NCIGT_Prostate:
- NCIGT_Prostate_Fully_Segmented:
- NCIGT_Brain_Biopsy:
Step 3. Disseminating & Sharing
- In addition to NCIGT mandate to share data, each effort listed above will have different requirements for being able to make data available to collaborating and other interested groups.
Outcome Metrics
Step 1. Data Management
Step 2. Query & Retrieval
Step 3. Dissemination & Sharing
Fundamental Requirements
Participants
- Mark Anderson
- Tina Kapur
Data
Workflows
Current Data Management Process
Target Data Management Process (Step 1.) Option A.
- Create new project using web GUI
- Manage project: Configure settings to automatically place data into the archive (no pre-archive)
- Create a subject template
- Create a spreadsheet conforming to subject template
- Upload spreadsheet to create subjects
- Run CLI Tool for batch anonymization (See here for HowTo: http://nrg.wustl.edu/projects/DICOM/DicomBrowser/batch-anon.html)
- Need pointer for script to do batch upload & apply DICOM metadata.
- Confirm data is uploaded & represented properly with web GUI
Target Data Management Process (Step 1.) Option B. (web services API) CURRENTLY BEING TESTED!
- Run CLI Tool for batch anonymization (See here for HowTo: http://nrg.wustl.edu/projects/DICOM/DicomBrowser/batch-anon.html)
- Create new project using web GUI
- Manage project: Configure settings to automatically place data into the archive (no pre-archive)
- Write script that uses curl or XNATRestClient (See here to download XNATRestClient in xnat_tools.zip from here: http://nrg.wikispaces.com/XNAT+REST+API+Usage)
1. Authenticate with server and create new session; use the response as a sessionID ($JSessionID) to use in subsequent queries
curl -d POST $XNE_Svr/REST/JSESSION -u $XNE_UserName:$XNE_Password or, use the XNATRestClient XNATRestClient -host $XNE_Svr -u $XNE_UserName -p $XNE_Password -m POST -remote /REST/JSESSION
2. Create subject
XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT /REST/projects/$ProjectID/subjects/s0001 (This will create a subject called 'S0001' within the project $ProjectID)
A script can be written to automatically create all subjects for the project.
2a. specify the demographics of a subject already created, or create with demographic specification
2.a.1 No demographics are applied to each subject by default. To edit the demographics (like gender or handedness) of a subject already created using XML Path shortcuts.
xnat:subjectData/demographics[@xsi:type=xnat:demographicData]/gender = male xnat:subjectData/demographics[@xsi:type=xnat:demographicData]/handedness = left
The entire command looks like this (Append XML path shortcuts and separate each by an &. Note that querystring parameters must be separated from the actual URI by a ?):
XNATRestClient -host $XNE_svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/s0001?xnat:subjectData/demographics[@xsi:type=xnat:demographicData]/gender=male&xnat:subjectData/demographics[@xsi:type=xnat:demographicData]/handedness=left"
All XML Path shortcuts that can be specified on commandline for projects, subject, experiments are listed here: http://nrg.wikispaces.com/XNAT+REST+XML+Path+Shortcuts
2.a.2 Alternatively, specify the demographics during subject creation by generating and uploading an xml file with the subject:
XNATRestClient -host $XNE_srv -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/s0002" - local ./$ProjectID_s0002.xml
The XML file you create and post looks like this:
<xnat:Subject ID="s0002" project="$ProjectID" group="control" label="1" src="12" xmlns:xnat="http://nrg.wustl.edu/xnat" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <xnat:demographics xsi:type="xnat:demographicData"> <xnat:dob>1990-09-08</xnat:dob> <xnat:gender>female</xnat:gender> <xnat:handedness>right</xnat:handedness> <xnat:education>12</xnat:education> <xnat:race>12</xnat:race> <xnat:ethnicity>12</xnat:ethnicity> <xnat:weight>12.0</xnat:weight> <xnat:height>12.0</xnat:height> </xnat:demographics> </xnat:Subject>
2.b Query the server to see what subjects have been created:
XNATRestClient -host $XNE_Svr -user_session $JSessionID -m GET -remote /REST/projects/$ProjectID/subjects
2.c Create experiments (collections of image data) you'd like to have for each subject
XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/$SubjectID/experiments/MRExperiment?xnat:mrSessionData/date=01/02/09" XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/$SubjectID/experiments/CTExperiment1?xnat:ctSessionData/date=01/02/09" XNATRestClient -host $XNE_Svr -user_session $JSessionID -m PUT -remote "/REST/projects/$ProjectID/subjects/$SubjectID/experiments/PETExperiment1?xnat:cpetSessionData/date=01/02/09"
3. Anonymize & Upload scan data
See here for new (possibly buggy) command line options: http://nrg.wustl.edu/projects/DICOM/DicomBrowser-cli.html
4. Confirm data is uploaded & represented properly with web GUI