Supporting Documentation FAQ

Page Overview

Folder Structure

All our data is typically organized in a folder structure as seen below:

[Project]>

        [Session] >

                     [Subject] >

                                 [Action] >

                                            [Trial] >

                                                     [Camera] > 

                                                                    [Video]

 

To achieve this folder structure, follow the 'Organizing Data' steps below.

Organizing Data

Before video data can be processed, it must be organized in a specific fashion required by Theia3D. The following steps describe the process of reorganizing downloaded data such that it can be processed using Theia3D.


Manually Build the List

  1. Open Theia3D 

  2. Under the ‘File’ menu, select ‘Organize Videos’. This will open the video formatting window. 

  3. For the Sony cameras, choose the ‘Advanced’ option. 

  4. Browse to the folder that contains the downloaded videos (it will appear empty) and open it in the formatting window. 

  5. In the window you should see all your trials (C000X-X) 

  6. Next, define your subjects. To do this, click the ‘Build Subjects’ button. From here you can choose the number of subjects you have. Keep in mind that one of the subjects will have to be for the calibration files so you will need to keep that in mind (For example, you collected data on two subjects, you will need to build three subjects to account for calibration). 

    Note: For the calibration, the subject name should be "Calibration". Subjects can be named according to the study for which the data was collected, or in a logical fashion if the data is for a one-time use (pilot testing, etc.).
  7. Once you have made your list of subjects click ‘Accept’ and close the 'Build Subjects' window. Then choose your first subject from the drop-down menu. When it is selected, select all of the video trials that are to be associated with that subject, click ‘Add’, and then click ‘Finish’. Repeat this for all subjects, including the calibration subject. 

  8. Once you have assigned all your video trials to a subject you can add actions to the trials. To do this click on the 'Build Actions' button. Similar to building subjects, you once again need to add the number of actions you have, with an extra action for calibration. When you have added all your actions, click ‘Accept’ and then close the window. 

    Note: For calibration files, use “Calibration”. Cannot use spaces or dashes. Use CamelCase or use under_scores. 
  9. Once your actions have been built you can add them to the appropriate video trials by selecting them, clicking ‘Add’ followed by ‘Finish’.

  10. Once you have assigned a subject and action to all the video files, click the ‘Format Data’ button and your data will be reorganized. 

    Note: Double check the data folder to ensure that the reorganization has worked and that no videos were left out. The data should now be organized as [subject folders] > [action folders] > [trial folders] > [camera folders] > [single video file]. The calibration trial data should be similarly organized, as Calibration (i.e. subject folder) > [trial folder] > [camera folders] > [single video file]; this formatting is required for the next step. 
  11.  You can now process your data, beginning with the calibration. 


Using Data Sheet

  1. Open Theia3D. 

  2. Under the ‘File’ menu, select ‘Organize Videos’. This will open the video formatting window. 

  3. For the Sony cameras, choose the ‘Advanced’ option. 

  4. Browse to the folder that contains the downloaded videos (it will appear empty) and open it in the formatting window. 

  5. In the window you should see all your trials (C000X-X). 

  6. Click the 'Load Subject Action Assignment' and locate your data sheet from that session. Example Data Collection Sheet:: mme/research/hmrl/MMOA/YYYY-MM-DD-subject-action-asssignment.csv Template.xlsx

  7. Make sure that the actions and trials match up.

  8. Once you have assigned a subject and action to all the video files, click the ‘Format Data’ button and your data will be reorganized. 

  9. Double check the data folder to ensure that the reorganization has worked and that no videos were left out. The data should now be organized as [subject folders] > [action folders] > [trial folders] > [camera folders] > [single video file]. The calibration trial data should be similarly organized, as Calibration (i.e. subject folder) > [trial folder] > [camera folders] > [single video file]; this formatting is required for the next step. 

  10. You can now process your data, beginning with the calibration. 

 

Using QR Codes 

  1. Using Spyder or integrated development environment of choice, open data server to access video files containing QR codes.

  2. Download the theiaQR.py script available on Jereme Outerleys’ Github or using the link provided: https://jouterleys.github.io/mmoa/

    Note: If accessing through the HMRL lab server, enter the hmrl-data server (X:) > TheiaUtils . TheiaQR > theiaQR.py
  3. In the ln53, labelled “barcode_camera_id”, insert the name of the serial number of the QR code data video from the camera.

  4. Browse the search directory and select the data folder containing the video files.

  5. Run the script. Files that do not have a QR code or do not display the QR code within the first 5 seconds of the video will read as “No Barcode Detected". These files will have to be manually rechecked to ensure the QR code is not after 5s mark.

  6. Within the data set folder, open the newly created .csv file called “subject-action-assignments” will be created. Ensure the first row (C0000#) is in sequential order.

  7. Prior to making any changes, copy the .cvs file and label the copy as “subject-action-assignments-fixed”.  Make all changes to the copy.

    Note: Files without a QR code detected will be flagged as “No Barcode Detected” within the second row. Check the preceding trial to see if the same participant has been previously detected with a barcode. If so, copy the participant barcode in the undetected column. If no other trials exist to draw a participant code from, leave the column marked as “No Barcode Detected”.