Skip to content

Commit

Permalink
2024-02-22 updates (#566)
Browse files Browse the repository at this point in the history
This PR:

- Updates the documentation for the tomcat.ivilab.org to describe the addition of the new sync and vocalic feature tables, updates to the existing tables, fixing of a couple of minor timestamp issues, and acknowledging the new ARL grant.
-  Updates the entity-relationship diagram for the database.
- Updates the `docker-compose.prod.yml`to use `inspect-data.json` instead of `inspect_file.json`
- Updates a couple of scripts to point to Paulo's subdirectory in `/space` instead of the users
- Updates the copy_screenshots_to_server script, and adds a .sh extension
  • Loading branch information
adarshp authored Feb 22, 2024
1 parent 70861b2 commit 76bb69a
Show file tree
Hide file tree
Showing 11 changed files with 183 additions and 22 deletions.

This file was deleted.

2 changes: 1 addition & 1 deletion human_experiments/datasette_interface/bin/launch_dev
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

set -euo pipefail
datasette \
/space/${USER}/tomcat/tomcat.db \
/space/paulosoares/tomcat/tomcat.db \
--metadata metadata.yml \
--reload \
--template-dir=templates \
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash

# Update inspect-data.json
time datasette inspect /space/$USER/tomcat/tomcat.db > inspect-data.json
time datasette inspect /space/paulosoares/tomcat/tomcat.db > inspect-data.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ services:
--metadata /repo/metadata.yml
--template-dir /repo/templates
--plugins-dir /repo/plugins
--inspect-file /repo/inspect_file.json
--inspect-file /repo/inspect-data.json
--static assets:/repo/static
--setting sql_time_limit_ms 10000
--setting facet_time_limit_ms 10000
Expand Down
78 changes: 78 additions & 0 deletions human_experiments/datasette_interface/inspect-data.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
{
"tomcat": {
"hash": "e658dd324b33f88e17a02a77b45a7e16f0807b719ddeba440b552968efb54eae",
"size": 460870664192,
"file": "/space/paulosoares/tomcat/tomcat.db",
"tables": {
"task": {
"count": 9
},
"modality": {
"count": 3
},
"group_session": {
"count": 40
},
"participant": {
"count": 114
},
"station": {
"count": 4
},
"rest_state_task": {
"count": 40
},
"ping_pong_competitive_task_observation": {
"count": 647242
},
"eeg_device": {
"count": 120
},
"affective_task_event": {
"count": 14586
},
"eeg_raw": {
"count": 320700934
},
"ping_pong_cooperative_task_observation": {
"count": 323806
},
"finger_tapping_task_observation": {
"count": 99875
},
"data_validity": {
"count": 3060
},
"gaze_raw": {
"count": 129554477
},
"minecraft_mission": {
"count": 100
},
"minecraft_testbed_message": {
"count": 6370941
},
"screen_capture": {
"count": 4100470
},
"audio_vocalics": {
"count": 33049497
},
"eeg_sync": {
"count": 124351398
},
"fnirs_raw": {
"count": 6849295
},
"fnirs_sync": {
"count": 125359661
},
"gsr_sync": {
"count": 124351398
},
"ekg_sync": {
"count": 97446792
}
}
}
}
Binary file modified human_experiments/datasette_interface/static/db_diagram.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions human_experiments/datasette_interface/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@

<ul class="dropdown-menu" aria-labelledby="navbarDropdownMenuLink">
<li><a class="dropdown-item" href="/updates">All updates</a></li>
<li><a class="dropdown-item" href="/updates/2024-02-22">2024-02-22</a></li>
<li><a class="dropdown-item" href="/updates/2023-07-19">2023-07-19</a></li>
<li><a class="dropdown-item" href="/updates/2023-07-17">2023-07-17</a></li>
</ul>
Expand Down
10 changes: 7 additions & 3 deletions human_experiments/datasette_interface/templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,13 @@ <h2 style="padding-left: 10px; border-left: 10px solid #{{ database.color }}">
{{ render_markdown("""
## Funding Acknowledgment

The creation of this dataset was funded by the Army Research Office and was
- The creation of this dataset was funded by the Army Research Office and was
accomplished under Grant Number W911NF-20-1-0002. The grant was awarded through
the Defense Advanced Research Projects Agency (DARPA). We would also like to
acknowledge intramural seed funding from the University of Arizona's SensorLab.
the Defense Advanced Research Projects Agency (DARPA).
- We would also like to acknowledge intramural seed funding from the University
of Arizona's SensorLab.
- Continued support (documentation updates, replying to questions from dataset
users, etc.) is supported by Army Research Office (ARO) Award Number
W911NF-24-2-0034.
""") }}
{% endblock %}
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@

## List of updates

- [2023-07-19](/updates/2023-07-19): This update adds the following:
- [2024-02-22](/updates/2024-02-22): Added new tables with vocalic data,
synchronized data, fixed a couple of data issues.
- [2023-07-19](/updates/2023-07-19): This update adds the following (see
[here](/updates/2023-07-19) for details):
- [Data Products document](http://ivilab.cs.arizona.edu/data/tomcat/data_products.pdf),
which contains descriptions of both the raw
data (this is primarily meant for internal documentation purposes) and the
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
{% extends "base.html" %}

{% block body_class %}index{% endblock %}

{% block content %}
{{ render_markdown(
"""
# 2024-02-22 update

## 1. New data

### 1.1 Synchronized physio data tables

Added new tables (`fnirs_sync`, `gsr_sync`, `eeg_sync`, and `ekg_sync`)
to store preprocessed signals synchronized to a main clock for four modalities
(fNIRS, GSR, EEG, and EKG) across experiments, with filtering for artifact
removal. For each experiment, a main clock was defined with start time at 5
seconds before the beginning of the first task (rest state), end time at 5
seconds after the end of last task (Minecraft), and frequency at 200 Hz.

The changes are introduced in this PR:
https://github.com/ml4ai/tomcat/pull/558.

### 1.2 Vocalic features table

Added a table called `audio_vocalics` that contains vocalic features extracted
using [OpenSMILE](https://github.com/audeering/opensmile/releases/tag/v3.0.0).

### 1.3 Updated `fnirs_raw` table

Expanded fNIRS data by adding raw signals for 760 nm and 850 nm wavelengths to
the `fnirs_raw` table, in case users wish to transform those into HbO and HbR
themselves.

### 1.4 Added advisor information

Added a column to the `group_session` table containing information about which
advisor was present during the trials.

## 2. Timestamp corrections

### 2.1 Timestamp corrections for exp_2023_01_31_14

**Summary**: Corrected Minecraft start/end timestamps for exp_2023_01_31_14
which had inconsistent dates in the future.

**Explanation**: `exp_2023_01_31_14` had dates for trial start/stop and mission
stop (same as trial stop due to the absence of a mission stop message in the
corresponding `.metadata` file) in the past due to inconsistency. We noticed
that the code was not taking the most recent trial dates into consideration in
case of multiple trial start/stop. We fixed the data processing code and
updated the dates manually. The wrong dates were causing the main clock not to
have any ticks because rest state (with correct timestamp) had timestamp after
the Minecraft task which is used to compute the final timestamp of the main
clock when synchronizing signals.

### 2.2 Timestamps for rest state task in exp_2022_12_05_12.

**Summary**: Added start and end timestamps for the rest state task in
`exp_2022_12_05_12`.

**Explanation**: If there are no start and end timestamps saved in the raw data
file for the rest state task (prior to 2023-04, the timestamps for the rest
state task were being saved in a CSV file), we use the file modification date
as an approximation to the start timestamp when it started and add 300 seconds
to the start timestamp to obtain the end timestamp. The file is created when
the task start so the offset should be minimal. So far, only experiment
`exp_2022_12_05_12` has this issue. We use the start time of the rest state
when defining the main clock, so having that information is important for us
not to lose any data.

## 3. Fixed swapped signals for EKG and GSR for some experiments.

Addressed an issue where EKG and GSR signals were swapped in specific
experiments:

- `exp_2022_09_30_10`
- `exp_2022_10_04_09` for the `lion` station
- `exp_2022_10_04_09` for the `tiger` station) by updating the raw EEG data
processing processing to swap the signals for these specific instances.

## Other updates

- Updated funding acknowledgment section on the landing page to include new
grant from ARO.
- Updated entity-relationship diagram.

""")
}}
{% endblock %}

0 comments on commit 76bb69a

Please sign in to comment.