Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

provenance for neuroimaging data

Project Description

provenance for neuroimaging data

Ever encountered a file of which you weren’t sure what analysis steps it had gone through? Ever wanted to know what types of data you have available for a subject in one overview? Automatically document an analysis pipeline?

Provenance is meta-data that tracks the ‘history’ of a file, and niprov is a python program to create, store and publish provenance for brain imaging files.

A list with all provenance attributes collected can be found here. Read more in the full online documentation (or pdf). For additional detailed information on image files, install nibabel,mne and/or pydicom.

Commandline Usage

Install niprov:

pip install niprov

Look for existing image files in your data directory:

provenance discover /my/data/directory

Run a transformation command and log it as provenance for the new file:

provenance record mcflirt -in t1flip_all_orig -out t1all_reg -refvol 0

Store provenance of known MEG files as an xml file:

provenance export --modality "MEG" --xml

Python API

import niprov
provenance = niprov.ProvenanceContext()

# Log an analysis step:
someAnalysisPackage.correctmotion(input='JD-fmri.nii', output='JD-fmri-3dmc.nii')
provenance.log('JD-fmri.nii', 'motion correction', ['JD-fmri-3dmc.nii'])

# Loop over images of John Smith and display a preview:
for image in provenance.get().bySubject('John Smith'):
    image.viewSnapshot()

# Make sure two files were acquired with the same parameters:
img1.compare(img2).assertEqualProtocol()

Web browser

By running the command provenance serve you can start a mini webserver in the background, and browse images in your webbrowser:

Release History

Release History

This version
History Node

0.5

History Node

0.4.1

History Node

0.4

History Node

0.3

History Node

0.2.1

History Node

0.2

History Node

0.1.post13

History Node

0.1.post12

History Node

0.1.post11

History Node

0.1.post10

History Node

0.1.post9

History Node

0.1.post8

History Node

0.1.post7

History Node

0.1.post6

History Node

0.1.post5

History Node

0.1.post4

History Node

0.1.post3

History Node

0.1.post2

History Node

0.1.post1

History Node

0.1

History Node

0.0

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
niprov-0.5.tar.gz (239.6 kB) Copy SHA256 Checksum SHA256 Source Jul 6, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting