Skip to content

nimh-dsst/nda-bids-upload

 
 

Repository files navigation

Welcome to the NIMH DSST NDA BIDS Upload Repository

bids-examples

This repository is for taking data as BIDS and uploading it to an NDA collection.

The full documentation lives here: ndabids.readthedocs.io

Quick Start

Installation

# Clone the repository with submodules
git clone --recursive https://github.com/nimh-dsst/nda-bids-upload.git
cd nda-bids-upload

# Install with uv (recommended)
uv pip install -e .

# Or with pip
pip install -e .

For detailed installation instructions, see INSTALL.md.

Usage

  1. Create a lookup.csv file to map BIDS subject/sessions to NDA GUID's

    # Run the script directly
    python -m utilities.lookup <source_dir> <destination_dir>
    
    # Or use the installed command
    nda-lookup <source_dir> <destination_dir>

    If you have your GUID's ready and want to enter them immediately you can append the --edit-now flag to the above command:

    nda-lookup <source_dir> <destination_dir> --edit-now

    image of lookup.csv editor

  2. Create file mapper json's and NDA Yaml files:

    # Run the script directly
    python -m utilities.mapping <source_dir> <destination_dir>
    
    # Or use the installed command
    nda-mapping <source_dir> <destination_dir>

    This produces mapper JSONs and YAMLs per BIDS datatype (e.g. anat, pet) and also image03_sourcedata.bids.toplevel (top-level BIDS files only: README, dataset_description.json, participants.tsv, etc.) for NDA image03 upload.

  3. Use file mapper and nda manifests tool to create packages for uploading to NDA:

    # Prepare data for NDA upload
    python prepare.py -s <source_dir> -d <destination_dir>
    
    # Or use the installed command
    nda-prepare -s <source_dir> -d <destination_dir>

Dependencies

This package includes:

All dependencies are managed via pyproject.toml for easy installation with uv or pip.

About

For uploading BIDS data to the NDA.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 99.9%
  • Makefile 0.1%