sift:tutorials:openbiomechanics_project:refine_queries_with_metadata
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
sift:tutorials:openbiomechanics_project:refine_queries_with_metadata [2024/07/17 15:42] – removed sgranger | sift:tutorials:openbiomechanics_project:refine_queries_with_metadata [2024/11/29 18:43] (current) – sgranger | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Refine Queries with Metadata ====== | ||
+ | |||
+ | Through the OpenBiomechanics Project, Driveline Baseball has made elite-level motion capture data publicly available. The data can be downloaded from [[https:// | ||
+ | |||
+ | Having access to large datasets is a great asset, but processing these large datasets can take time (and patience). Sift is designed to streamline this process. The steps in this tutorial describe how to create [[visual3d: | ||
+ | |||
+ | ===== Downloads and Relevant Links ===== | ||
+ | |||
+ | Begin by downloading the following two zip files. | ||
+ | |||
+ | - [[https:// | ||
+ | - [[https:// | ||
+ | |||
+ | Please note, these downloads contain a large amount of data. Building CMZs is a slow process, so if you want to speed it up to follow along with building CMZ portion of this tutorial cut the number of datasets under openbiomechanics-main down to 3-5 subjects. | ||
+ | |||
+ | If you want to skip the Build CMZ step of this tutorial and focus on the metadata applications, | ||
+ | |||
+ | * download [[https:// | ||
+ | * skip to the [[Other: | ||
+ | |||
+ | For more technical information about loading metadata, see: [[Other: | ||
+ | |||
+ | ===== Build CMZs for Hitting Data ===== | ||
+ | |||
+ | First open a new Sift workspace.\\ | ||
+ | |||
+ | On the [[sift: | ||
+ | |||
+ | In the [[sift: | ||
+ | |||
+ | - **Set the path to:** C: | ||
+ | - **Set the Metadata File to :** C: | ||
+ | - **Set the MDH File to:** C: | ||
+ | - Add the following scripts and ensure they are in the correct order: | ||
+ | - C: | ||
+ | - C: | ||
+ | - C: | ||
+ | {{ sift: | ||
+ | - Click **Create CMZs** | ||
+ | - A metadata dialog box will appear after clicking Create CMZs. Make the following changes in this box: | ||
+ | - Height Units: in | ||
+ | - Weight Units: Lb | ||
+ | - session_swing: | ||
+ | - user: Static Trial Identifier | ||
+ | - Check " | ||
+ | - CMZ files may take a while to build. Check the status bar in the bottom left hand corner of the interface for the build status. | ||
+ | - After the files are built, check that the Library Path dialog is set correctly and hit " | ||
+ | - On the [[: | ||
+ | {{ : | ||
+ | ==== Refining Hitting Data ==== | ||
+ | |||
+ | From here on it is assumed that you either have: a) built CMZs from scratch using the hitting data set, or b) downloaded the pre-made CMZs linked above. | ||
+ | |||
+ | The zip file openbiomechanics-main has a metadata file for the hitting data set which you can view at your convenience. This metadata file has a number of categories including player age, bat weight, hitting side etc. | ||
+ | |||
+ | Let's say we want to query this data set, but we **only** want data from subjects that are under age 20. | ||
+ | |||
+ | We start by loading library with the hitting data set, navigating to the [[sift: | ||
+ | |||
+ | Under " | ||
+ | |||
+ | Additional refinements, | ||
+ | |||
+ | {{sift: | ||
+ | |||
+ | When refining queries it can be helpful to have the metadata file open, so that you can see the values it contains. Note that in this case, accessing athlete_age has been set as a global metric, and you will not be able to find the meta folder unless Global Value is checked. | ||
+ | |||
+ | The result of this procedure is that data is queried only if it meets this refinement category, and the refinement name will be applied as a suffix to the end of the signal name. | ||
+ | |||
+ | When you hit " | ||
+ | {{ : | ||
+ | |||
+ | ===== Build Your Own Metadata File ===== | ||
+ | |||
+ | Let's say you have three subjects worth of data where each subject walks at four different speeds and has a different weight. | ||
+ | |||
+ | In this example let us say we want to include metadata on the subject' | ||
+ | |||
+ | In the example below, we can see that there are four headers (static_model, | ||
+ | |||
+ | {{: | ||
+ | |||
+ | Here you can edit the description fields and subject specific fields. After you are satisfied with the fields, click " | ||
+ | |||
+ | ==== Using Metadata to Refine Queries ==== | ||
+ | |||
+ | Once your data is loaded it can be queried. This example shows how you can use metadata to refine queries. | ||
+ | |||
+ | In this instance, we have data where three subjects walk at three different speeds. | ||
+ | |||
+ | If you navigate from the Query Builder dialog to the Auto-Populate menu, In the **Signals** tab Select **Metric** as the signal type and **meta** as the signal folder. Now switch over to the **Refinements** tab, click {{: | ||
+ | |||
+ | {{: | ||
+ | |||
+ | |||
+ | {{: | ||
+ | |||
+ | |||
+ | |||
+ | \\ | ||
+ | |||
+ | |||
+ | Since I want to refine my data by walking speed in this example, I name the refinement " | ||
+ | |||
+ | {{: | ||
+ | |||
+ | ==== Visualizing Refined Queries ==== | ||
+ | |||
+ | In this example we can visualize the metric data for all three subjects walking at three different speeds. | ||
+ | |||
+ | Insure that **Plot Type** is set to Metric Plot, then check the boxes for **Select All Groups** and **Select All Workspaces**. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | |||
sift/tutorials/openbiomechanics_project/refine_queries_with_metadata.1721230921.txt.gz · Last modified: 2024/07/17 15:42 by sgranger