Skip to main content

MRQy is a quality assurance and checking tool for quantitative assessment of magnetic resonance imaging (MRI) data.

Project description

Picture1

Front-end View

gbm_mrqy

Backend View

gbm_mrqy

Description

This tool takes MRI datasets in the file formats (_.dcm_, _.nii_, _.nii.gz_ or _.mha_) as the input. Two Python scripts (QC.py and QCF.py) are used to generate several tags and noise/information measurements for quality assessment. These scripts save the calculated measures in a _.tsv_ file as well as generate _.png_ thumbnails for all images in a subject volume. These are then fed to _.js_ scripts to create the user interface (index.html) output. A schematic illustrating the framework of the tool is as follows.

Framework schematic

Prerequisites

The current version of the tool has been tested on the Python 3.6+ You must have pipenv installed on your environment to run MRQy locally. It will pull all the dependencies listed in the diagram.

Dependencies diagram

You can also likely install the python requirements using something like:

pip3 install -r requirements.txt

Running

For local development, test that the code is functional

MRQy % pipenv shell
(mrqy) MRQy% pipenv install .
(mrqy) MRQy% python -m mrqy.QC --help

The output should be

usage: QC.py [-h] output_folder_name [inputdir [inputdir ...]]

positional arguments:
  output_folder_name  the subfolder name on the
                      '...\UserInterface\Data\output_folder_name' directory.
  inputdir            input foldername consists of *.mha (*.nii or *.dcm)
                      files. For example: 'E:\Data\Rectal\input_data_folder'

optional arguments:
  -h, --help          show this help message and exit

Standard usage is to run QC.py output_folder_name “input directory” i.e.

python QC.py output_folder_name "E:\Data\Rectal\RectalCancer_Multisite\input_data_folder"

There is no need to make a subfolder in the Data directory, just specify its name in the command as in the above code. Every action will be printed in the output console. The thumbnail images in the format of _.png_ will be saved in “…UserInterfaceDataoutput_folder_name” with its original filename as the subfolder name. Afterward, double click “index.html” (on e.g. “D:DownloadsMRQy-masterUserInterface”) to open front-end user interface, and select the respective results.tsv file from the correct location e.g. “D:DownloadsMRQy-masterUserInterfaceDataoutput_folder_name” directory.

Contribution guidelines

Testing

MRQy % pipenv shell
(mrqy) MRQy% pipenv install .
(mrqy) MRQY% pipenv run -m pytest tests/

Building on Travis

The recommended path is to follow the Forking Workflow. Create a Travis CI build for your github fork to validate your fork before pushing a merge request to master.

Basic Information

Measurements

The measures of the MRQy tool are listed in the following table.

Measurements table

User Interface

The following figures show the user interface of the tool (index.html).

UI example 1 UI example 2 UI example 3

Feedback and usage

Please report and issues, bugfixes, ideas for enhancements via the “Issues” tab.

Detailed usage instructions and an example of using MRQy to analyze TCIA datasets are in the Wiki.

You can cite this in any associated publication as: Sadri, AR, Janowczyk, A, Zou, R, Verma, R, Beig, N, Antunes, J, Madabhushi, A, Tiwari, P, Viswanath, SE, “Technical Note: MRQy — An open-source tool for quality control of MR imaging data”, Med. Phys., 2020, 47: 6029-6038. https://doi.org/10.1002/mp.14593

ArXiv: https://arxiv.org/abs/2004.04871

If you do use the tool in your own work, please drop us a line to let us know.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mrqy-0.0.3.tar.gz (15.7 kB view details)

Uploaded Source

Built Distribution

mrqy-0.0.3-py3-none-any.whl (17.2 kB view details)

Uploaded Python 3

File details

Details for the file mrqy-0.0.3.tar.gz.

File metadata

  • Download URL: mrqy-0.0.3.tar.gz
  • Upload date:
  • Size: 15.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.2

File hashes

Hashes for mrqy-0.0.3.tar.gz
Algorithm Hash digest
SHA256 86bf6b1cf2645b9e046cc626b81a98a439468532f160b2effaabac004fb96f94
MD5 0b25278bc4acb423f2526f1f789c2aa9
BLAKE2b-256 27bfd5fc2eee6c8f1207b150d38692a76901a6a57b34a8bdbc5a8c1b7f7e5063

See more details on using hashes here.

File details

Details for the file mrqy-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: mrqy-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 17.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.2

File hashes

Hashes for mrqy-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 4c75b3086578bf1bf1e3eca8566454f1a5a64a97b46f63fca19fdffc5d9c7d2f
MD5 cd41f8ad7591cdab6fba02903ad3e659
BLAKE2b-256 c95c3897c30bcce3fec7796de32b37cfc6380c1970b4f7e72377fdcd88fb35e5

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page