Code Monkey home page Code Monkey logo

aslbids's Introduction

aslbids

This code helps to convert ASL data to bids format as propopsed in ASLBIDS

First, the dicom files need to be convereted to bids with heudiconv and require heuristic file.

For example with sample heuritic file (heuristic.py)

heudiconv --files dicomdirectory -s subjectid -ss session_id -o outputbidsdirectory --bids -f heuristic.py

Second step is to edit ASL json files with edit_aslbids.py. It require json files (see example metadataextra.jon that contain extra metadata for ASL,MO and mean CBF as proposed in ASLBIDS. The metadataextra.jon also has asllabel to be specify for each volume to write out the aslcontext.

The most important paremeters required for ASLPREP are::

        "ArterialLabelingType": labeling type, either PCASL or ASL
        "LabelingDuration": labeling duraion in seconds
        "PostLabelingDelay": post labeling delayin seconds
        "BackgroundSuppression": Yes or no
        "M0Scale": MO scale , defualt is 1
        "LabelingEfficiency": default are use depending on labeling type (PCASL or ASL)

edit_aslbids.py -s SUBJECT_ID -t SESSION_ID -b BIDS_DIR -j JSONTEMPLATE

  1. SUBJECT_ID > subject id e.g sub-XX, require
  2. SESSION_ID > session id e.g ses-YY, require if the bids has seission
  3. BIDS_DIR > bids output of heudiconv
  4. JSONTEMPLATE > metadetata for asl,m0 and mean CBF, there is sample here (metadataextra.json) and should be edited as required

On flywheel using fw-heudiconv, the extra metadata and ASLContext files can be specified in your heuristic during curation.

  1. Use the tabulate tool to extract your ASL parameters from DICOM headers
  2. Use the MetadataExtras variable to hard code these parameters (see example)
  3. Dynamically create the ASLContext file in your heuristic (see example)
  4. Re-curate your dataset

aslbids's People

Contributors

a3sha2 avatar tinashemtapera avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.