NeuroJSON.io client - neuroj
217

Primary tools:
neuroj: NeuroJSON client - the primary utility that calls other tools to convert and query NeuroJSON.ionjprep: a bash script to convert databases, single dataset or single data fileHelper functions (called by neuroj and njprep)
bids2json: a utility to merge converted dataset JSON files to a single datasetname.json file for uploadlink2json: a utility to create a JSON file for symbolic linkslistdatalink: a utility to list/extract all URL/externally linked data files (_DataLink_) for batch downloadmergejson: a bash/jq script to merge all converted files under a subject-folder to a single subject.jbids filetsv2json: a Perl script to convert tsv/csv to JSON # print help information and flags
docker run openjdata/neuroj:v2025
# preview commands (dry-run, does not execute) to convert a database (including all included datasets) to JSON
docker run openjdata/neuroj:v2025 neuroj -i /path/to/database/rootfolder -o /path/to/output/json/folder -db openneuro
# convert a database (a collection of datasets) to JSON in batch with 12 parallel threads (1 thread per dataset)
docker run openjdata/neuroj:v2025 neuroj -i /path/to/database/rootfolder -o /path/to/output/json/folder -db openneuro --convert -t 12
# convert a single dataset (including all files under sub-folders) to JSON in parallel (1 thread per file)
docker run openjdata/neuroj:v2025 neuroj -i /path/to/database/rootfolder -o /path/to/output/json/folder -db openneuro -ds ds000001 --convert
# convert a database to JSON, assuming the last segment of the input path as database name
docker run openjdata/neuroj:v2025 neuroj -i /path/to/database/databasename -o /path/to/output/json/folder
# convert a single dataset ds000001 to JSON (dry-run only, add --convert to run)
docker run openjdata/neuroj:v2025 neuroj -i /path/to/database/databasename -o /path/to/output/json/folder -ds ds000001
# convert all datasets under openneuro to JSON using 30 parallel threads, processing 30 files in parallel
docker run openjdata/neuroj:v2025 neuroj -i /path/to/database/rootfolder -o /path/to/output/json/folder -db openneuro -ds \\* --convert -t 30
# once dataset.json files are converted in the output folder, push all .json files to NeuroJSON.io (admin only)
docker run openjdata/neuroj:v2025 neuroj -o /path/to/output/json/folder -db openneuro --push -n
# upload /path/to/output/json/folder/ds000005.json to neurojson.io:7777/openneuro database
docker run openjdata/neuroj:v2025 neuroj -o /path/to/output/json/folder -db openneuro -ds ds000005 --push -n
# list all databases currently hosted on NeuroJSON.io
docker run openjdata/neuroj:v2025 neuroj --list
# list all databases currently hosted on NeuroJSON.io, format the output with jq
docker run openjdata/neuroj:v2025 neuroj --list | jq '.'
# list all datasets stored under the 'openneuro' database
docker run openjdata/neuroj:v2025 neuroj --list -db openneuro
# list all datasets strored under the 'openneuro' database and print all datasets using jq filters
neuroj --list -db openneuro | jq '.rows[] | .id'
# query server-level information of the database openneuro (return dataset count, file sizes etc)
docker run openjdata/neuroj:v2025 neuroj --info -db openneuro
# search the IDs of the first 10 (limit:10) datasets in the openneuro database starting from the 3rd (skip:2) datasets
docker run openjdata/neuroj:v2025 neuroj -db openneuro --find '{"selector":{},"fields":["_id"],"limit":10,"skip":2}'
# query the dataset name "_id" and "dataset_description.json" records of the first two datasets in "openneuro" and format with jq
docker run openjdata/neuroj:v2025 neuroj -db openneuro --find '{"selector":{},"fields":["_id","dataset_description\\\\.json"],"limit":2}' | jq '.'
# set default external link URL template
export NJPREP_FALLBACK_URL="https://neurojson.org/io/stat.cgi?action=get&db=%DB%&doc=%DS%"
# convert all datasets in a database to JSON
docker run openjdata/neuroj:v2025 njprep /database/root/ /output/json/root/ database_name
# convert a specific dataset "dataset_name" in a specific database to JSON
docker run openjdata/neuroj:v2025 njprep /database/root/ /output/json/root/ database_name dataset_name
# convert a single file or subject-folder in a given database and dataset
docker run openjdata/neuroj:v2025 njprep /database/root/ /output/json/root/ database_name dataset_name /path/to/a/file
Content type
Image
Digest
sha256:9b9e2c800…
Size
517.2 MB
Last updated
5 months ago
docker pull openjdata/neuroj:v2026