Skip to content

[SCHEMA] BEP028 - BIDS-Prov #2098

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 16 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/schema/objects/entities.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,14 @@ processing:
exploited.
type: string
format: label
prov:
name: prov
display_name: Provenance group
description: |
A grouping of provenance records.
Defining multiple provenance records groups is appropriate when several processings have been performed on data.
type: string
format: label
reconstruction:
name: rec
display_name: Reconstruction
Expand Down
7 changes: 7 additions & 0 deletions src/schema/objects/files.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,13 @@ code:
(for example the one used to generate the derivatives from the raw data).
See the [Code section](SPEC_ROOT/modality-agnostic-files.md#code)
for more information.
prov:
display_name: Provenance Records
file_type: directory
description: |
A directory in which to store provenance metadata.
See the [Provenance section](SPEC_ROOT/modality-agnostic-files.md#provenance)
for more information.
derivatives:
display_name: Derivative data
file_type: directory
Expand Down
39 changes: 39 additions & 0 deletions src/schema/objects/metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1281,6 +1281,32 @@ GeneratedBy:
URI:
type: string
format: uri
GeneratedBy:
name: GeneratedBy
display_name: Generated By
description: |
Specify the provenance of a file in the dataset, referencing the Id
of the Activity (or Activities) responsible for its creation.
anyOf:
- type: string
format: uri
- type: array
items:
type: string
format: uri
GeneratedByProv:
name: GeneratedByProv
display_name: Generated By Prov
description: |
Specify the provenance of the dataset, referencing the Id
of the Activity (or Activities) responsible for its creation.
anyOf:
- type: string
format: uri
- type: array
items:
type: string
format: uri
GeneticLevel:
name: GeneticLevel
display_name: Genetic Level
Expand Down Expand Up @@ -3292,6 +3318,19 @@ ShortChannelCount:
The number of short channels. 0 indicates no short channels.
type: integer
minimum: 0
SidecarGeneratedBy:
name: SidecarGeneratedBy
display_name: Sidecar Generated By
description: |
Specify the provenance of a sidecar JSON,
referencing the Id of the Activity (or Activities) responsible for its creation.
anyOf:
- type: string
format: uri
- type: array
items:
type: string
format: uri
SinglesRate:
name: SinglesRate
display_name: Singles Rate
Expand Down
35 changes: 35 additions & 0 deletions src/schema/objects/suffixes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -502,6 +502,18 @@ VFA:
Depending on the provided metadata fields and the sequence type,
data may be eligible for DESPOT1, DESPOT2 and their variants
([Deoni et al. 2005](https://doi.org/10.1002/mrm.20314)).
act:
value: act
display_name: Provenance Activity Records
description: |
Provenance Activity records for a group of provenance.
Activities represent the transformations that have been applied to the data.
all:
value: all
display_name: Provenance Records
description: |
All types of provenance records (Activity, Entity, Environment, Software)
for a group of provenance.
angio:
value: angio
display_name: Angiogram
Expand All @@ -528,6 +540,11 @@ asllabeling:
A deidentified screenshot of the planning of the labeling slab/plane
with respect to the imaging slab or slices.
This screenshot is based on DICOM macro C.8.13.5.14.
base:
value: base
display_name: Base for Provenance Records
description: |
Base fields for provenance records of a group of provenance.
beh:
value: beh
display_name: Behavioral recording
Expand Down Expand Up @@ -612,6 +629,18 @@ electrodes:
display_name: Electrodes
description: |
File that gives the location of (i)EEG electrodes.
ent:
value: ent
display_name: Provenance Entity Records
description: |
Provenance Entity records for a group of provenance.
Entities are inputs and outputs of Activities.
env:
value: env
display_name: Provenance Environment Records
description: |
Provenance Environment records for a group of provenance.
Environments specify the software environment in which the provenance record was obtained.
epi:
value: epi
display_name: EPI
Expand Down Expand Up @@ -817,6 +846,12 @@ probseg:
A probabilistic segmentation.

This suffix may only be used in derivative datasets.
soft:
value: soft
display_name: Provenance Software Records
description: |
Provenance Software records for a group of provenance.
The Software specifies the software package with which transformations were applied to the data.
sbref:
value: sbref
display_name: Single-band reference image
Expand Down
1 change: 1 addition & 0 deletions src/schema/rules/checks/deprecations.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
AnatomicalLandmarkCoordinateSystemDeprecation:
issue:
code: ELEKTA_NEUROMAG_DEPRECATED
Expand Down
6 changes: 4 additions & 2 deletions src/schema/rules/dataset_metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ dataset_description:
EthicsApprovals: optional
ReferencesAndLinks: optional
DatasetDOI: optional
GeneratedBy: recommended
GeneratedBy: deprecated
GeneratedByProv: recommended
SourceDatasets: recommended

dataset_authors:
Expand All @@ -38,7 +39,8 @@ derivative_description:
- path == "/dataset_description.json"
- json.DatasetType == "derivative"
fields:
GeneratedBy: required
GeneratedByProv: recommended
GeneratedBy: deprecated

dataset_description_with_genetics:
selectors:
Expand Down
11 changes: 11 additions & 0 deletions src/schema/rules/directories.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ raw:
- derivatives
- logs
- phenotype
- prov
- sourcedata
- stimuli
- subject
Expand All @@ -46,6 +47,10 @@ raw:
name: phenotype
level: optional
opaque: false
prov:
name: prov
level: optional
opaque: false
sourcedata:
name: sourcedata
level: optional
Expand All @@ -72,6 +77,7 @@ raw:
value: datatype
level: required
opaque: false
subdirs:

derivative:
root:
Expand All @@ -80,6 +86,7 @@ derivative:
- derivatives
- logs
- phenotype
- prov
- sourcedata
- stimuli
- subject
Expand All @@ -99,6 +106,10 @@ derivative:
name: phenotype
level: optional
opaque: false
prov:
name: prov
level: optional
opaque: false
sourcedata:
name: sourcedata
level: optional
Expand Down
1 change: 1 addition & 0 deletions src/schema/rules/entities.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@
- density
- label
- description
- prov
3 changes: 3 additions & 0 deletions src/schema/rules/files/common/core.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ code:
derivatives:
level: optional
path: derivatives
prov:
level: optional
path: prov
docs:
level: optional
path: docs
Expand Down
17 changes: 17 additions & 0 deletions src/schema/rules/files/common/modality_agnostic.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
# Files and directories that can be found at any level of a dataset.

# Provenance json files
provenance:
level: optional
path: prov/*
suffixes:
- act
- base
- ent
- env
- soft
extensions:
- .json
entities:
prov: required
3 changes: 3 additions & 0 deletions src/schema/rules/files/common/tables.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ participants:
extensions:
- .tsv
- .json

samples:
level: optional
stem: samples
extensions:
- .tsv
- .json

scans:
level: optional
suffixes:
Expand All @@ -21,6 +23,7 @@ scans:
entities:
subject: required
session: optional # session is required if session is present in the dataset.

sessions: # This file may only exist if session is present in the dataset.
level: optional
suffixes:
Expand Down
Loading