Last active
December 18, 2018 15:59
-
-
Save tlimpanont/d1f3e1263722c3af3154282a233f7ca5 to your computer and use it in GitHub Desktop.
GraphQL data examples for IMAGR
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type PipelineStep { | |
id: ID! @unique | |
stepOrder: Int | |
definition: StepDefinition | |
} | |
enum MODULE_TYPE { | |
DOCKER | |
} | |
type StepDefinition { | |
id: ID! @unique | |
name: String | |
version: String | |
description: String | |
type: MODULE_TYPE #really required for UI? | |
config: Json | |
owner: String | |
inputRequired: Boolean | |
inputInstructionText: String | |
} | |
type PipelineRun { | |
id: ID! @unique | |
pipeline: Pipeline | |
study: Study | |
startTime: DateTime | |
endTime: DateTime | |
currentPipelineStep: Int # reference to PipelineStep.stepOrder | |
following: Following #depends on which user request it (userDn ? true : false) | |
} | |
type Pipeline { | |
id: ID! @unique | |
description: String | |
name: String | |
version: String | |
owner: String | |
steps: [PipelineStep] | |
pipelineRuns: [PipelineRun] | |
} | |
type WebPushSubscription { | |
id: ID! @unique | |
payload: Json | |
userDn: String | |
} | |
enum NOTIFICATION_TYPE { | |
COMPLETED | |
INPUT_REQUIRED | |
} | |
type Notification { | |
id: ID! @unique | |
following: Following | |
message: String | |
type: NOTIFICATION_TYPE | |
} | |
enum RESOURCE_TYPE { | |
STUDY | |
PIPELINE_RUN | |
} | |
type Following { | |
id: ID! @unique | |
resourceType: RESOURCE_TYPE | |
resourceId: String | |
userDn: String #ldap user_dn | |
} | |
type ViewedStudy { | |
id: ID! @unique | |
study: Study | |
userDn: String #ldap user_dn | |
} | |
type UserActivityType { | |
root: String | |
message: [String] | |
} | |
type UserActivity { | |
id: ID! @unique | |
type: UserActivityType | |
userDn: String #ldap user_dn | |
} | |
type Study { | |
id: ID! @unique | |
description: String | |
pacsID: Int, | |
status: Int | |
patient: Patient | |
dicomTags: Json | |
following: Following #depends on which user request it (userDn ? true : false) | |
pipelineRuns: [PipelineRun] | |
viewedStudy: ViewedStudy #depends on which user request it (userDn ? true : false) | |
} | |
enum PATIENT_SEX { | |
M | |
F | |
} | |
type Patient { | |
id: ID! @unique | |
pacsID: Int, | |
name: String | |
dateOfBirth: DateTime | |
sex: PATIENT_SEX | |
studies: [Study] | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
query searchAllStudiesByPatient { | |
studies(where:{patient:{name_contains: "Snoei, W."}}) { | |
UUID | |
StudyUID | |
id | |
status | |
dicomTags | |
} | |
} | |
query searchAllPipelinesByStudyUID { | |
studies(where:{StudyUID:"1.23.280.3452315.324556734.2435326352435"}) { | |
UUID | |
pipelines { | |
version | |
owner | |
steps { | |
module { | |
version | |
name | |
description | |
} | |
} | |
} | |
} | |
} | |
query allStudies { | |
studies { | |
patient { | |
name | |
dateOfBirth | |
} | |
StudyUID | |
UUID | |
status | |
dicomTags | |
} | |
} | |
query allPatients { | |
patients { | |
name | |
dateOfBirth | |
sex | |
} | |
} | |
query allPipelines { | |
pipelines { | |
id | |
name | |
steps { | |
id | |
config | |
module{ | |
name | |
description | |
} | |
} | |
} | |
} | |
query allPipelineSteps { | |
pipelineSteps { | |
version | |
module { | |
name | |
description | |
} | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mutation seed { | |
patientDeVries: createPatient( | |
data: { | |
PatientID: "0663537" | |
name: "de Vries, M." | |
sex: F | |
dateOfBirth: "1976-07-12" | |
} | |
) { | |
id | |
} | |
patientKaagman: createPatient( | |
data: { | |
PatientID: "7635672" | |
name: "Kaagman, S.I." | |
sex: M | |
dateOfBirth: "1994-03-22" | |
} | |
) { | |
id | |
} | |
patientMonai: createPatient( | |
data: { | |
PatientID: "8728565" | |
name: "Monai, F." | |
sex: M | |
dateOfBirth: "2008-06-09" | |
} | |
) { | |
id | |
} | |
patientvanDerMeulen: createPatient( | |
data: { | |
PatientID: "0826735" | |
name: "van der Meulen, V.E" | |
sex: F | |
dateOfBirth: "1978-02-15" | |
} | |
) { | |
id | |
} | |
someStudy: createStudy( | |
data: { | |
status: 0 | |
UUID: "a998d963-1dc1-4330-b5c8-773f581a83f1" | |
StudyUID: "1.23.280.3452315.324556734.2435326352435" | |
dicomTags: "{ \"Series\": [{ \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 8, \"SeriesDescription\": \"For Series: 501 - 502\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472349253245800001.5548457636467850249\", \"Modality\": \"ECG\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": \"-Unavailable-\", \"Columns\": 8 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": \"-Unavailable-\", \"SeriesDescription\": \"-Unavailable-\", \"SeriesUID\": \"1.2.752.24.7.1715200030.1002167876.1017982845\", \"Modality\": \"PR\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": \"-Unavailable-\", \"Columns\": \"-Unavailable-\" }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 1096, \"SeriesDescription\": \"CS DISPLAY\", \"SeriesUID\": \"1.3.46.670589.50.2.885095009672858182.30674945053595174185\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": \"-Unavailable-\", \"Columns\": 1655 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 512, \"SeriesDescription\": \"FB AX BL CS 3/3, 78%\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472258692066000001.5080226402361951721\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": 3.0, \"SliceThickness\": 3.0, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"Iodine\", \"Rows\": 512, \"SeriesDescription\": \"L6 AX , 78%, iDose (6)\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472348765217900001.5669825355795180723\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": 0.45, \"SliceThickness\": 0.9, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"Iodine\", \"Rows\": \"-Ambiguous-\", \"SeriesDescription\": \"Tracker Graph\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472333165325600001.4877511275926803969\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": \"-Unavailable-\", \"Columns\": \"-Ambiguous-\" }, { \"ContrastBolusAgent\": \"Iodine\", \"Rows\": 512, \"SeriesDescription\": \"tracker\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472302488571000001.4695701438295156941\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": 0.0, \"SliceThickness\": 10.0, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"Iodine\", \"Rows\": 512, \"SeriesDescription\": \"COR\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472465701906200001.5265255198400443699\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": 3.0, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 512, \"SeriesDescription\": \"locator\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472286756671200001.5206769057472987654\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": 0.0, \"SliceThickness\": 10.0, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"Iodine\", \"Rows\": 512, \"SeriesDescription\": \"L6 AX +EC, 78%, iDose (6)\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472348765217900002.5034671938743842364\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": 0.45, \"SliceThickness\": 0.9, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 512, \"SeriesDescription\": \"TS_AX BL CS 0.9, 78%\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472258692066000002.5486234696360832609\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": 0.45, \"SliceThickness\": 0.9, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 8, \"SeriesDescription\": \"For Series: 201 - 202\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472259014084400001.4948942121495298769\", \"Modality\": \"ECG\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": \"-Unavailable-\", \"Columns\": 8 }, { \"ContrastBolusAgent\": \"Iodine\", \"Rows\": 512, \"SeriesDescription\": \"SAG\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472494730566600001.5411705172507071784\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": 3.0, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": 282, \"SeriesDescription\": \"SV\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472137044108100001.5658498417753816297\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": 0.625, \"Columns\": 512 }, { \"ContrastBolusAgent\": \"-Unavailable-\", \"Rows\": \"-Ambiguous-\", \"SeriesDescription\": \"Exam Summary\", \"SeriesUID\": \"1.3.46.670589.33.1.63659472419850283700001.4923704017678269861\", \"Modality\": \"CT\", \"SpacingBetweenSlices\": \"-Unavailable-\", \"SliceThickness\": \"-Ambiguous-\", \"Columns\": \"-Ambiguous-\" }], \"StudyDescription\": \"CT HART - CORONAIREN\", \"PatientID\": \"1336331\", \"StudyUID\": \"1.3.46.670589.33.1.63659471808147296300001.5406241173742551393\", \"PatientBirthDate\": \"19950511\" }" | |
patient: { | |
create: { | |
PatientID: "8965344" | |
name: "Snoei, W." | |
sex: F | |
dateOfBirth: "1986-04-01" | |
} | |
} | |
pipelines: { | |
create: [ | |
{ | |
name: "CAT12 segmentation" | |
version: "r1258" | |
owner: "Hugo Kuijf" | |
steps: { | |
create: [ | |
{ | |
version: "0.1" | |
config: "{\"command\": \"dcm2nii -x n -o /mnt/working /mnt/input\" }" | |
module: { | |
create: { | |
name: "Dicom2NifTi" | |
version: "1.0" | |
description: "Convert a dicom image into the NifTi format" | |
type: DOCKER | |
runTimeout: 86400 | |
owner: "Hugo Kuijf" | |
} | |
} | |
} | |
{ | |
version: "r1258" | |
config: "{ \"command\": \"python /spm/run_cat.py\" }" | |
module: { | |
create: { | |
name: "CAT12" | |
version: "r1258" | |
description: "Construction and assessment of spatially extended statistical processes used to test hypotheses about functional imaging data" | |
type: DOCKER | |
runTimeout: 86400 | |
owner: "Hugo Kuijf" | |
} | |
} | |
} | |
] | |
} | |
} | |
] | |
} | |
} | |
) { | |
id | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment