Skip to content

Commit 7e3747a

Browse files
committed
update after (near-)finalization of fields/columns; add example image
1 parent 6cf70f7 commit 7e3747a

File tree

9 files changed

+274
-167
lines changed

9 files changed

+274
-167
lines changed

src/modality-specific-files/electromyography.md

Lines changed: 134 additions & 109 deletions
Large diffs are not rendered by default.
Loading

src/schema/objects/columns.yaml

Lines changed: 40 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,13 @@ component:
8989
- $ref: objects.enums.quat_y.value
9090
- $ref: objects.enums.quat_z.value
9191
- $ref: objects.enums.quat_w.value
92+
coordinate_system:
93+
name: coordinate_system
94+
display_name: Coordinate System
95+
description: |
96+
Name of the coordinate system defined in `coordsystem.json` in which the electrode's
97+
`x`, `y`, and (optionally) `z` coordinates are given.
98+
type: string
9299
detector__channels:
93100
name: detector
94101
display_name: Detector Name
@@ -252,6 +259,15 @@ index:
252259
description: |
253260
The label integer index.
254261
type: integer
262+
interelectrode_distance:
263+
name: interelectrode_distance
264+
display_name: Interelectrode Distance
265+
description: |
266+
Distance between adjacent electrodes (in a pair or grid) that are rigidly attached to
267+
the same sensor device, or between the `signal_electrode` and its `reference` when
268+
each is independently placed.
269+
type: number
270+
unit: mm
255271
low_cutoff:
256272
name: low_cutoff
257273
display_name: Low cutoff
@@ -372,12 +388,11 @@ participant_id:
372388
matching a participant entity found in the dataset.
373389
type: string
374390
pattern: ^sub-[0-9a-zA-Z]+$
375-
# TODO revisit whether example is sufficient
376391
placement__emg:
377392
name: placement
378-
display_name: Placement
393+
display_name: Placement Scheme
379394
description: |
380-
Placement of the electrode(s) on the body (for example, "palmar side of lower arm").
395+
Placement of the sensor(s) on the body (for example, "palmar side of lower arm").
381396
It can refer to an external vocabulary for describing body parts.
382397
type: string
383398
placement__motion:
@@ -403,20 +418,20 @@ reference__eeg:
403418
This column is not needed when it is common to all channels.
404419
In that case the reference electrode(s) can be specified in `*_eeg.json` as `EEGReference`).
405420
type: string
406-
# reference column for channels.tsv files for iEEG data
407-
reference__ieeg:
421+
# reference column for channels.tsv files for EMG data
422+
reference__emg:
408423
name: reference
409424
display_name: Electrode reference
410425
description: |
411-
Specification of the reference (for example, `mastoid`, `ElectrodeName01`, `intracranial`, `CAR`, `other`, `n/a`).
412-
If the channel is not an electrode channel (for example, a microphone channel) use `n/a`.
426+
Specification of the reference (for example, `ulnar styloid process`, `ElectrodeName01`, `n/a`).
413427
type: string
414-
# reference column for channels.tsv files for EMG data
415-
reference__emg:
428+
# reference column for channels.tsv files for iEEG data
429+
reference__ieeg:
416430
name: reference
417431
display_name: Electrode reference
418432
description: |
419-
Specification of the reference (for example, `ulnar styloid process`, `ElectrodeName01`, `n/a`).
433+
Specification of the reference (for example, `mastoid`, `ElectrodeName01`, `intracranial`, `CAR`, `other`, `n/a`).
434+
If the channel is not an electrode channel (for example, a microphone channel) use `n/a`.
420435
type: string
421436
reference_frame:
422437
name: reference_frame
@@ -524,6 +539,13 @@ short_channel:
524539
The total number of channels listed as short channels
525540
SHOULD be stored in `ShortChannelCount` in `*_nirs.json`.
526541
type: boolean
542+
signal_electrode:
543+
name: signal_electrode
544+
display_name: Signal electrode
545+
description:
546+
The name of the electrode from which the `reference` electrode is subtracted, to yield
547+
the channel's data.
548+
type: string
527549
size:
528550
name: size
529551
display_name: Electrode size
@@ -618,6 +640,14 @@ strain_rrid:
618640
of the strain of the species, for example: `RRID:IMSR_JAX:000664`.
619641
type: string
620642
format: rrid
643+
target_muscle:
644+
name: target_muscle
645+
display_name: Target muscle
646+
description: |
647+
Name of the muscle(s) from which the EMG signal in this channel is believed to originate.
648+
When exact muscle is unknown (such as when using electrode grids that cover multiple muscles),
649+
groups of muscles may be named instead (for example "flexors of the left forearm").
650+
type: string
621651
time:
622652
name: time
623653
display_name: Time

src/schema/objects/enums.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,6 @@ _EEGCoordSys:
77
- $ref: objects.enums.EEGLAB.value
88
- $ref: objects.enums.EEGLAB-HJ.value
99
- $ref: objects.enums.Other.value
10-
# TODO: I think "Other" is all we want at this point, since SENIAM isn't a coordsystem
11-
# and anything else will need to specify origin and axis directions relative to
12-
# skeletal landmarks in `EMGCoordinateSystemDescription`. But we should probably
13-
# still define this (single-element) enum now, so it's easier to add predefined
14-
# coordinate systems later (since we know folks are working on publishing them).
1510
_EMGCoordSys:
1611
type: string
1712
enum:

src/schema/objects/metadata.yaml

Lines changed: 70 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,21 @@ ACCELChannelCount:
99
Number of acceleration channels.
1010
type: integer
1111
minimum: 0
12+
AnchorCoordinates:
13+
name: AnchorCoordinates
14+
display_name: Anchor Coordinates
15+
description: |
16+
Coordinates of the `AnchorElectrode` in the parent (anatomical) coordinate system.
17+
This should be an array of numbers of length 3, in the units given in
18+
`EMGCoordinateSystemUnits` within the JSON object named in `ParentCoordinateSystem`.
19+
type: array
20+
AnchorElectrode:
21+
name: AnchorElectrode
22+
display_name: Anchor Electrode
23+
description: |
24+
Name of the electrode in the child (device) coordinate system whose coordinates in
25+
the parent (anatomical) coordinate system are given in `AnchorCoordinates`.
26+
type: string
1227
Acknowledgements:
1328
name: Acknowledgements
1429
display_name: Acknowledgements
@@ -909,6 +924,18 @@ EEGReference:
909924
this field should have a general description and the channel specific
910925
reference should be defined in the `channels.tsv` file.
911926
type: string
927+
ElectrodeMaterial:
928+
name: ElectrodeMaterial
929+
display_name: Electrode Material
930+
description: |
931+
Material of the electrode (for example, `Tin`, `Ag/AgCl`, `Gold`).
932+
type: string
933+
ElectrodeType:
934+
name: ElectrodeType
935+
display_name: Electrode type
936+
description: |
937+
Type of the electrode (for example, cup, ring, clip-on, wire, needle).
938+
type: string
912939
EMGChannelCount:
913940
name: EMGChannelCount
914941
display_name: EMG Channel Count
@@ -958,27 +985,38 @@ EMGGround:
958985
type: string
959986
EMGPlacementScheme:
960987
name: EMGPlacementScheme
961-
display_name: EMG Placement Procedure
988+
display_name: EMG Placement Scheme
962989
description: |
963990
The name of a standardized electrode placement procedure (for example, `"SENIAM 8"`)
964991
or a description of the procedure used.
965-
Descriptions SHOULD reflect the process used by the researcher(s) when placing electrodes,
966-
and SHOULD NOT simply give the name of the targeted muscle (use `TargetMuscle` for that).
967-
For example, EMG electrode sites may be chosen by visual reference to target muscles,
968-
by palpation of the skin to locate target muscles, by functional localization
992+
Descriptions SHOULD NOT simply give the name of the targeted muscle (use the
993+
`target_muscle` column in `channels.tsv` for that), but rather SHOULD reflect the
994+
process used by the researcher(s) when placing electrodes.
995+
For example, EMG electrode sites may be chosen by *visual reference* to target muscles,
996+
by *palpation* of the skin to locate target muscles, by *functional localization*
969997
(temporary electrode placement at several sites during prescribed behavior,
970-
until a site yielding strong EMG signal is found), or by measured distances
998+
until a site yielding strong EMG signal is found), or by *measured distances*
971999
(either absolute or proportional) relative to skeletal landmarks.
1000+
In datasets involving multiple EMG recording units placed at different sites in which
1001+
different placement procedures were used for different sites, the procedures for each
1002+
site SHOULD be described in the `placement_scheme` column of `channels.tsv` instead,
1003+
and the value of `EMGPlacementScheme` SHOULD be a non-empty string such as
1004+
"channel-specific" or "see channels.tsv" or similar.
9721005
type: string
9731006
EMGReference:
9741007
name: EMGReference
9751008
display_name: EMG Reference
9761009
description: |
977-
Description of the reference scheme used and (when applicable) of location of the
978-
reference electrode in the raw recordings (for example, `"left ulnar styloid process"`).
979-
For bipolar channels, specify `EMGReference` as "bipolar".
980-
If different channels have different references, this field should contain a general
981-
description and the channel specific reference should be defined in the `channels.tsv` file.
1010+
Description of the reference electrode location when the same reference was used for
1011+
all channels (often called a "monopolar" recording).
1012+
If different channels have different reference electrodes, this field should contain
1013+
a non-empty string such as "channel-specific" and each channel-specific reference
1014+
should be described in the `reference` column of `channels.tsv`.
1015+
For bipolar recording devices (where a single sensor unit contains two rigidly
1016+
separated contacts, and the paired contacts are not listed independently in
1017+
`electrodes.tsv`), the value of `reference` (in `channels.tsv`, for single channels)
1018+
or `EMGReference` (in `emg.json`, when all channels were bipolar) should be "bipolar".
1019+
9821020
type: string
9831021
EOGChannelCount:
9841022
name: EOGChannelCount
@@ -1770,6 +1808,13 @@ IntendedFor__ds_relative:
17701808
format: bids_uri
17711809
- type: string
17721810
format: dataset_relative
1811+
InterelectrodeDistance:
1812+
name: InterelectrodeDistance
1813+
display_name: Interelectrode Distance
1814+
description: |
1815+
Distance between pairs or grids of electrodes rigidly attached to the same sensor device.
1816+
type: number
1817+
unit: mm
17731818
InversionTime:
17741819
name: InversionTime
17751820
display_name: Inversion Time
@@ -2560,6 +2605,13 @@ ParallelReductionFactorOutOfPlane:
25602605
as they imply different methods of accelerating the acquisition.
25612606
Corresponds to DICOM Tag 0018, 9155 `Parallel Reduction Factor out-of-plane`.
25622607
type: number
2608+
ParentCoordinateSystem:
2609+
name: ParentCoordinateSystem
2610+
display_name: Parent Coordinate System
2611+
description: |
2612+
The name of a JSON mapping key that defines the parent (anatomical) coordinate system
2613+
in which this child (device) coordinate system is anchored.
2614+
type: string
25632615
PartialFourier:
25642616
name: PartialFourier
25652617
display_name: Partial Fourier
@@ -3357,6 +3409,13 @@ SinglesRate:
33573409
type: array
33583410
items:
33593411
type: number
3412+
SkinPreparation:
3413+
name: SkinPreparation
3414+
display_name: Skin Preparation
3415+
description: |
3416+
How skin was prepared prior to sensor device placement, for example, `"alcohol wipe"`
3417+
or `"abrasive gel"`.
3418+
type: string
33603419
SkullStripped:
33613420
name: SkullStripped
33623421
display_name: Skull Stripped

src/schema/objects/suffixes.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -612,6 +612,11 @@ electrodes:
612612
display_name: Electrodes
613613
description: |
614614
File that gives the location of (i)EEG electrodes.
615+
emg:
616+
value: emg
617+
display_name: Electromyography
618+
description: |
619+
Electromyography recording data.
615620
epi:
616621
value: epi
617622
display_name: EPI

src/schema/rules/json/emg.yaml

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,6 @@
55
# Assumptions: top-to-bottom overrides is sufficient logic
66

77
---
8-
# General fields
9-
EMGCoordsystemGeneral:
10-
selectors:
11-
- datatype == "emg"
12-
- suffix == "coordsystem"
13-
fields:
14-
IntendedFor:
15-
level: optional
16-
description_addendum: |
17-
This identifies the origin and axes directions for coordinate systems
18-
used to describe digitized EMG electrode locations.
19-
208
# Fields relating to the EMG electrode positions
219
EMGCoordsystemPositions:
2210
selectors:
@@ -38,17 +26,15 @@ EMGCoordsystemOther:
3826
fields:
3927
EMGCoordinateSystemDescription: required
4028

41-
# Fields relating to the position of anatomical landmark measured during an EMG session/run
42-
EMGCoordsystemLandmark:
29+
# Fields relating to the linkage between child (device) and parent (anatomical) coordinate systems
30+
EMGCoordsystemAnchor:
4331
selectors:
4432
- datatype == "emg"
4533
- suffix == "coordsystem"
4634
fields:
47-
AnatomicalLandmarkCoordinates: recommended
48-
AnatomicalLandmarkCoordinateSystem:
49-
level: recommended
50-
description_addendum: Preferably the same as the `EMGCoordinateSystem`.
51-
AnatomicalLandmarkCoordinateUnits: recommended
35+
ParentCoordinateSystem: optional
36+
AnchorCoordinates: optional
37+
AnchorElectrode: optional
5238

5339
EMGCoordsystemLandmarkDescriptionRec:
5440
selectors:

src/schema/rules/sidecars/emg.yaml

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -73,24 +73,22 @@ EMGRecommended:
7373
EMGGround: recommended
7474
EpochLength: recommended
7575
HardwareFilters: recommended
76+
InterelectrodeDistance: recommended
7677
RecordingDuration: recommended
7778
RecordingType: recommended
7879
SubjectArtefactDescription: recommended
79-
TargetMuscle: recommended
8080
TriggerChannelCount: recommended
8181

8282
# Specific EMG fields MAY be present
83-
# TODO: InterElectrodeDistance: in channels.tsv probably, only for bipolar channels
84-
# ElectrodeGroup: not sure this is still needed given our use of `acq`
85-
# ElectrodeOrientation: incorporate into EMGPlacementScheme?
86-
# SkinPreparation: abrasive gel, alcohol wipe
83+
# TODO: do we want/need any of these?
84+
# ECGChannelCount: optional
85+
# EOGChannelCount: optional
86+
# MISCChannelCount: optional
87+
# ElectricalStimulation: optional
88+
# ElectricalStimulationParameters: optional
8789
EMGOptional:
8890
selectors:
8991
- datatype == "emg"
9092
- suffix == "emg"
9193
fields:
92-
ECGChannelCount: optional
93-
EOGChannelCount: optional
94-
MISCChannelCount: optional
95-
ElectricalStimulation: optional
96-
ElectricalStimulationParameters: optional
94+
SkinPreparation: optional

src/schema/rules/tabular_data/emg.yaml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,18 @@ EMGChannels:
1414
units: required
1515
description: optional
1616
sampling_frequency: optional
17-
reference__emg: optional
17+
signal_electrode: recommended
18+
reference__emg: recommended
19+
group__channel: recommended
20+
target_muscle: recommended
21+
placement__emg: recommended
22+
interelectrode_distance: recommended
1823
low_cutoff: optional
1924
high_cutoff: optional
2025
notch: optional
2126
status: optional
2227
status_description: optional
23-
index_columns: [name__channels]
28+
index_columns: [name__channels, group__channels]
2429
additional_columns: allowed_if_defined
2530

2631
EMGElectrodes:
@@ -33,13 +38,17 @@ EMGElectrodes:
3338
- x
3439
- y
3540
- z
41+
- coordinate_system
3642
columns:
3743
name__electrodes: required
3844
x: required
3945
y: required
4046
z: optional
47+
coordinate_system: required
4148
type__electrodes: recommended
4249
material: recommended
4350
impedance: recommended
44-
index_columns: [name__electrodes]
51+
group__channel: recommended
52+
placement__emg: optional
53+
index_columns: [name__electrodes, group__channel]
4554
additional_columns: allowed_if_defined

0 commit comments

Comments
 (0)