Handling “TSV_INDEX_VALUE_NOT_UNIQUE” When Uploading Non-Imaging Clinical Data to OpenNeuro

Hi everyone,

I’m trying to upload a BIDS-compliant dataset containing both neuroimaging and clinical data to OpenNeuro, and I’ve run into some issues. I’d like to get some advice from the community. Here’s my data situation:

  1. Each participant has a unique MRI scan (structural MRI) associated with their participant_id.
  2. The clinical data include multiple hospital visits, blood tests, ECGs, etc. Some participants have multiple records under the same participant_id.
  3. When I upload, the OpenNeuro validator gives this error:
TSV_INDEX_VALUE_NOT_UNIQUE /phenotype/biochemical.tsv - Row: 14, Value: sub-358

I understand this happens because OpenNeuro expects unique participant_id values in TSV files, while my clinical data contain multiple records per participant.

I’ve found two possible ways to handle this:

  • Add a session or visit column for multiple records so that each entry has a unique index in BIDS. But participants may have multiple hospital visits, sometimes there are even multiple tests per hospital visit. It is hard to add a session.
  • Use .bidsignore to ignore non-imaging duplicate data and only upload the necessary phenotype data once per participant. I tried using .bidsignore, but it didn’t seem to work.

So I have a few questions:

  1. What’s the recommended way to handle a participant who has multiple non-imaging records but only one MRI in BIDS/OpenNeuro?
  2. Is it possible to upload multiple clinical records without triggering TSV_INDEX_VALUE_NOT_UNIQUE?
  3. Can .bidsignore fully ignore these non-imaging duplicate records? Has anyone done this in practice?

Thanks a lot for your advice and experience!

Directory structure of my dataset:

D:\data\vertigo_data\
├── dataset_description.json
├── participants.tsv
├── participants.json
├── phenotype\
│   ├── biochemical.tsv
│   ├── complete_blood_count.tsv
│   ├── clinical.tsv
│   └── ecg.tsv
├── sub-001\
│   └── anat\
│       ├── sub-001_T1w.nii.gz
│       └── sub-001_FLAIR.nii.gz
├── sub-002\
│   └── anat\
│       ├── sub-002_T1w.nii.gz
│       └── sub-002_FLAIR.nii.gz

Hi @river, and welcome to neurostars!

I think you could either (1) Make your TSV longer, with unique column names that reflect the session index; (2) make one tsv/json pair per session; (3) try .bidsignore. I would imagine that (2) would be the most BIDS compliant.

Best,
Steven

For what it’s worth, I believe the current phenotype BEP (see https://github.com/bids-standard/bids-specification/pull/2123) will allow session_id and run_id columns in phenotype TSV file to allow multiple rows per participant. I don’t know when that BEP will be merged into BIDS, but organizing your data according to the BEP and adding the BEP-but-not-BIDS-compliant files to the bidsignore for now might be a good way of preparing for when the BEP is merged.