XNAT Workshop 2012

XNAT2012 - Image Session Validation

Video: 


Goal:

At the end of this session, attendees should be able to:

  • Create a schematron rule file

  • Launch image session validation

Material:

Pre-requisites:

  • Working knowledge of XML and XPATH

Tasks during the talk:

Step 1: Adding a pipeline to a site

We would add the pipeline /opt/xnat/pipeline_1_6/catalog/validation_tools/Validate.xml to the site

  • Login to XNAT as Admin.

  • Navigate to Administer -> Pipelines

  • Click on Add Pipeline to Repository

  • Input:

    • Enter Path to Pipeline descriptor xml:   /opt/xnat/pipeline_1_6/catalog/validation_tools/Validate.xml

    • Enter Name of the custom webpage to launch this pipeline: PipelineScreen_protocolcheck.vm

    • Click on Add

    • You will get a message "... was added successfully”

    • If you did everything correct, you will see ProtocolCheck listed in the pipeline repository.


 Step 2: Upload the schematron file as a resource to project BOGUS_OUA

 

  • cd /opt/xnat/workshop2012/d2s1-validation

  • /opt/xnat/pipeline_1_6/xnat-tools/XNATRestClient -host

    http://localhost:8080/xnat -u

    admin -p

    admin -m

    PUT -remote

    "/data/archive/projects/BOGUS_OUA/resources/validation_xnat_mrSessionData"

  • /opt/xnat/pipeline_1_6/xnat-tools/XNATRestClient -host http://localhost:8080/xnat -u admin -p admin -m PUT -remote "/data/archive/projects/BOGUS_OUA/resources/validation_xnat_mrSessionData/files?content=v1.0"

    -local /opt/xnat/workshop2012/d2s1-validation/mrsession_rules.sch

  • ALTERNATIVELY: curl  -i -u admin:admin -X PUT -T mrsession_rules.sch http://localhost:8080/xnat/data/archive/projects/BOGUS_OUA/resources/validation_xnat_mrSessionData/files?content=v1.0&inbody=true

 Step 3: Setting up the pipeline for the project BOGUS_OUA

            Navigate to BOGUS_OUA project as project owner

     Step 4: Setup the datatype

    • As Admin, click on Administer -> Data types

    • Select xnat:mrSessionData

    • Under Available Report Actions, enter

      • Name:  PipelineScreen_launch_pipeline,

      • Display Name: Build,

      • Popup: always,

      • Secure Access: edit

      • (leave other columns empty)

     Step 5: Launching the pipeline (via Action -> Build)

    • Navigate to project BOGUS_OUA

    • Select an MRSession

    • Click on Action -> Build

    • Select ProtocolCheck

    • Click on Submit

     Step 6: Launching the pipeline automatically

    • Upload a MR Session

    • Archive the session