Skip to content

Commit

Permalink
Create DrumTutorial
Browse files Browse the repository at this point in the history
5 sets of videos of adults and toddlers drumming
  • Loading branch information
InfantLab committed Mar 13, 2022
1 parent 0d8ea0f commit 0526c16
Show file tree
Hide file tree
Showing 45 changed files with 4,010 additions and 428 deletions.
32 changes: 32 additions & 0 deletions Drum.Tutorial.settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"batchName": "VASC Drumming Data tutorial",
"lastUpdate": null,
"flags":{
"anon": false,
"includeHands": true,
"cleaned": false
},
"paths":{
"openpose":"C:\\Users\\cas\\openpose-1.5.0-binaries-win64-gpu-python-flir-3d_recommended\\",
"project": ".\\DrumTutorial",
"videos_in": ".\\DrumTutorial\\videos",
"videos_out": ".\\DrumTutorial\\",
"videos_out_openpose": ".\\DrumTutorial\\openpose",
"videos_out_timeseries": ".\\DrumTutorial\\timeseries",
"videos_out_analyses" : ".\\DrumTutorial\\analyses"
},
"filenames":{
"videos_json": "videos.json",
"clean_json": "clean.json",
"alldatanpz": "allframedata.npz",
"lefthandnpz": "lefthandframedata.npz",
"righthandnpz": "righthandframedata.npz",
"lefthandnpz": "lefthandframedata.npz",
"cleannpz": "cleandata.npz",
"cleanrightnpz": "cleanrightdata.npz",
"cleanleftnpz": "cleanleftdata.npz",
"cleandataparquet": "cleandata.parquet",
"righthandparquet": "righthand.parquet",
"lefthandparquet": "lefthand.parquet"
}
}
Binary file added DrumTutorial/timeseries/allframedata.npz
Binary file not shown.
Binary file added DrumTutorial/timeseries/lefthandframedata.npz
Binary file not shown.
Binary file added DrumTutorial/timeseries/righthandframedata.npz
Binary file not shown.
1 change: 1 addition & 0 deletions DrumTutorial/videos.json

Large diffs are not rendered by default.

Binary file added DrumTutorial/videos/1fa339b_04-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/1fa339b_06-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/1fa339b_08-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/1fa339b_10-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/1fa339b_12-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/1fa339b_14-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/768fa72_04-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/768fa72_06-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/768fa72_08-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/768fa72_10-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/768fa72_12-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/768fa72_14-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/CasparA_04-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/CasparA_06-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/CasparA_08-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/CasparA_10-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/CasparA_12-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/CasparA_14-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/SineadR_04-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/SineadR_06-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/SineadR_08-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/SineadR_10-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/SineadR_12-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/SineadR_14-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/b22644a_04-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/b22644a_06-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/b22644a_08-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/b22644a_10-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/b22644a_12-test-trials.mp4
Binary file not shown.
Binary file added DrumTutorial/videos/b22644a_14-test-trials.mp4
Binary file not shown.
36 changes: 15 additions & 21 deletions Step0.GettingStarted.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,11 @@
"source": [
"### 0.0 - Jupyter notebook environment\n",
"\n",
"*If you can read this you are probably already running [Jupyter](https://jupyter.org/). Congratulations!*\n",
"*If you can read this you are probably already running Jupyter. Congratulations!*\n",
"\n",
"There's a [getting started guide](https://jupyter.readthedocs.io/en/latest/content-quickstart.html) at the [Jupyter documentation page](https://jupyter.readthedocs.io/en/latest/index.html)\n",
"We recommend using the Anaconda Data Science platform (Python 3 version) \n",
"\n",
"If you're impatient we recommend using the Anaconda Data Science platform (Python 3 version) \n",
"https://www.anaconda.com/distribution/\n",
"\n",
"and then running the command\n",
"```\n",
"conda install -c conda-forge jupyterlab\n",
"```\n",
"\n",
"These notebooks will run in the original Jupyter Notebook format or with the newer JupyterLab interface. We recommend the latter. "
"https://www.anaconda.com/distribution/\n"
]
},
{
Expand All @@ -45,16 +37,14 @@
"\n",
"Additionally, you need to download the trained neural-network models that OpenPose uses. To do this go to the `models` subdirectory of OpenPose directory, and double-click / run the `models.bat` script.\n",
"\n",
"The `openposedemo` bin/exe file can be run manually from the command line. It is worth trying this first so you understand what `openposedemo` is. See [this guide](https://github.com/CMU-Perceptual-Computing-Lab/openpose/blob/master/doc/demo_overview.md) or open a terminal app or Windows Powershell, navigate to the openpose installation folder and then try this command \n",
"The `openposedemo` bin/exe file can be run manually from the command line. It is worth trying this first so you understand what `openposedemo` is. See [this guide](https://github.com/CMU-Perceptual-Computing-Lab/openpose/blob/master/doc/demo_overview.md) or open a terminal app or Windows Powershell, navigate to the openpose installation folder and then try this command\n",
"\n",
"```\n",
":: Windows\n",
"bin\\OpenPoseDemo.exe --video examples\\media\\video.avi --write_json output\n",
"# Mac/Linux\n",
"./build/examples/openpose/openpose.bin --video examples/media/video.avi --write_json output\n",
"```\n",
"\n",
"Changing the `examples\\media\\video.avi` to the path to another video on your machine will process that instead. "
"```"
]
},
{
Expand All @@ -65,14 +55,14 @@
"\n",
"There are a handful of python libraries that we use for things like image manipulation, file operations, maths and stats. Many are probably already installed by default such as `os, math, numpy, pandas, matplotlib`. Others need adding to our python environment. \n",
"\n",
"For example, `PyArrow` is a useful extension for saving Pandas and NumPy data. We need it to move the large array created in Step 2 to Step 3. \n",
"PyArrow is a useful extension for saving Pandas and NumPy data. We need it to move the large array created in Step 2 to Step 3. \n",
"\n",
"**If you are using conda then run the following command to install all the main libraries.**\n",
"```\n",
"conda install glob2 opencv pyarrow xlrd openpyxl\n",
"```\n",
"#### Troubleshooting\n",
"When you run the code in Steps 1, 2 & 3 you might see an error like `ModuleNotFoundError: No module named 'glob'` this is because that python module needs to be installed on your computer. If you use Anaconda, the missing module can usually be installed with the command `conda install glob`. You then need to restart the script with the problem by choosing `Restart kernel..` from the Kernel menu dropdown."
"If when you run the code in Steps 1, 2 & 3 you might see an error like `ModuleNotFoundError: No module named 'glob'` this is because that python module needs to be installed on your computer. If you use Anaconda, the missing module can usually be installed with the command `conda install glob`."
]
},
{
Expand All @@ -89,6 +79,10 @@
"To make these work with the newer Jupyter Lab we also need to install the widgets lab extension, like so:\n",
"\n",
"```\n",
"Jupyter 3.0 (current)\n",
"conda install -c conda-forge jupyterlab_widgets\n",
"\n",
"Jupyter 2.0 (older)\n",
"conda install -c conda-forge nodejs\n",
"jupyter labextension install @jupyter-widgets/jupyterlab-manager\n",
"jupyter labextension install @jupyter-widgets/jupyterlab-manager ipycanvas\n",
Expand All @@ -106,7 +100,7 @@
"source": [
"### 0.4 - JupyText \n",
"\n",
"The standard ipython notebook format (`mynotebook.ipynb`) is a single file that mixes together code, formatting commands and outputs both as the results of running code and embedded binaries (images, graphs). This makes it non-human readable and very hard to tell what changed from one version to the next. `Jupytext` solves this by creating a synchronised plain text version of the file saved as a plain `.py` file (`mynotebook.py`). These are useful for developers (as it helps you track differences between versions more easily) but can mostly be ignored by users. \n",
"The standard ipython notebook format (`mynotebook.ipynb`) is a single file that mixes together code, formatting commands and outputs both as the results of running code and embedded binaries (images, graphs). This makes it non-human readable and very hard to tell what changes from one improvement to the next. `Jupytext` solves this by creating a synchronised plain text version of the file saved as a plain `.py` file (`mynotebook.py`). These are useful for developers (as it helps you track differences between versions more easily) but can mostly be ignored by users. \n",
"\n",
"\n",
"Install JupyText by running\n",
Expand All @@ -118,7 +112,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"### 0.5 Notebook extensions (optional)\n",
"### 0.6 Notebook extensions (optional)\n",
"Installing Jupyter notebook extenstions provide some useful tools for navigating notebooks (e.g. table of contents) and other features.\n",
"\n",
"To install, run these commands in terminal window.\n",
Expand Down Expand Up @@ -148,7 +142,7 @@
"formats": "ipynb,py:light"
},
"kernelspec": {
"display_name": "Python 3",
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
Expand All @@ -162,7 +156,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.5"
"version": "3.8.12"
}
},
"nbformat": 4,
Expand Down
29 changes: 12 additions & 17 deletions Step0.GettingStarted.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# format_version: '1.5'
# jupytext_version: 1.7.1
# kernelspec:
# display_name: Python 3
# display_name: Python 3 (ipykernel)
# language: python
# name: python3
# ---
Expand All @@ -24,49 +24,40 @@

# ### 0.0 - Jupyter notebook environment
#
# *If you can read this you are probably already running [Jupyter](https://jupyter.org/). Congratulations!*
# *If you can read this you are probably already running Jupyter. Congratulations!*
#
# There's a [getting started guide](https://jupyter.readthedocs.io/en/latest/content-quickstart.html) at the [Jupyter documentation page](https://jupyter.readthedocs.io/en/latest/index.html)
# We recommend using the Anaconda Data Science platform (Python 3 version)
#
# If you're impatient we recommend using the Anaconda Data Science platform (Python 3 version)
# https://www.anaconda.com/distribution/
#
# and then running the command
# ```
# conda install -c conda-forge jupyterlab
# ```
#
# These notebooks will run in the original Jupyter Notebook format or with the newer JupyterLab interface. We recommend the latter.

# ### 0.1 - OpenPoseDemo application
#
# Next we need to download and install the [OpenPoseDemo](https://github.com/CMU-Perceptual-Computing-Lab/openpose/blob/master/doc/demo_overview.md) executable.
#
# Additionally, you need to download the trained neural-network models that OpenPose uses. To do this go to the `models` subdirectory of OpenPose directory, and double-click / run the `models.bat` script.
#
# The `openposedemo` bin/exe file can be run manually from the command line. It is worth trying this first so you understand what `openposedemo` is. See [this guide](https://github.com/CMU-Perceptual-Computing-Lab/openpose/blob/master/doc/demo_overview.md) or open a terminal app or Windows Powershell, navigate to the openpose installation folder and then try this command
# The `openposedemo` bin/exe file can be run manually from the command line. It is worth trying this first so you understand what `openposedemo` is. See [this guide](https://github.com/CMU-Perceptual-Computing-Lab/openpose/blob/master/doc/demo_overview.md) or open a terminal app or Windows Powershell, navigate to the openpose installation folder and then try this command
#
# ```
# :: Windows
# bin\OpenPoseDemo.exe --video examples\media\video.avi --write_json output
# # Mac/Linux
# ./build/examples/openpose/openpose.bin --video examples/media/video.avi --write_json output
# ```
#
# Changing the `examples\media\video.avi` to the path to another video on your machine will process that instead.

# ### 0.2 - Load python libraries
#
# There are a handful of python libraries that we use for things like image manipulation, file operations, maths and stats. Many are probably already installed by default such as `os, math, numpy, pandas, matplotlib`. Others need adding to our python environment.
#
# For example, `PyArrow` is a useful extension for saving Pandas and NumPy data. We need it to move the large array created in Step 2 to Step 3.
# PyArrow is a useful extension for saving Pandas and NumPy data. We need it to move the large array created in Step 2 to Step 3.
#
# **If you are using conda then run the following command to install all the main libraries.**
# ```
# conda install glob2 opencv pyarrow xlrd openpyxl
# ```
# #### Troubleshooting
# When you run the code in Steps 1, 2 & 3 you might see an error like `ModuleNotFoundError: No module named 'glob'` this is because that python module needs to be installed on your computer. If you use Anaconda, the missing module can usually be installed with the command `conda install glob`. You then need to restart the script with the problem by choosing `Restart kernel..` from the Kernel menu dropdown.
# If when you run the code in Steps 1, 2 & 3 you might see an error like `ModuleNotFoundError: No module named 'glob'` this is because that python module needs to be installed on your computer. If you use Anaconda, the missing module can usually be installed with the command `conda install glob`.

# ### 0.3 - iPyWidgets
#
Expand All @@ -78,6 +69,10 @@
# To make these work with the newer Jupyter Lab we also need to install the widgets lab extension, like so:
#
# ```
# Jupyter 3.0 (current)
# conda install -c conda-forge jupyterlab_widgets
#
# Jupyter 2.0 (older)
# conda install -c conda-forge nodejs
# jupyter labextension install @jupyter-widgets/jupyterlab-manager
# jupyter labextension install @jupyter-widgets/jupyterlab-manager ipycanvas
Expand All @@ -91,14 +86,14 @@

# ### 0.4 - JupyText
#
# The standard ipython notebook format (`mynotebook.ipynb`) is a single file that mixes together code, formatting commands and outputs both as the results of running code and embedded binaries (images, graphs). This makes it non-human readable and very hard to tell what changed from one version to the next. `Jupytext` solves this by creating a synchronised plain text version of the file saved as a plain `.py` file (`mynotebook.py`). These are useful for developers (as it helps you track differences between versions more easily) but can mostly be ignored by users.
# The standard ipython notebook format (`mynotebook.ipynb`) is a single file that mixes together code, formatting commands and outputs both as the results of running code and embedded binaries (images, graphs). This makes it non-human readable and very hard to tell what changes from one improvement to the next. `Jupytext` solves this by creating a synchronised plain text version of the file saved as a plain `.py` file (`mynotebook.py`). These are useful for developers (as it helps you track differences between versions more easily) but can mostly be ignored by users.
#
#
# Install JupyText by running
#
# ```conda install -c conda-forge jupytext```

# ### 0.5 Notebook extensions (optional)
# ### 0.6 Notebook extensions (optional)
# Installing Jupyter notebook extenstions provide some useful tools for navigating notebooks (e.g. table of contents) and other features.
#
# To install, run these commands in terminal window.
Expand Down
Loading

0 comments on commit 0526c16

Please sign in to comment.