Analysis Module
Comparing OpenFace data to parameters and storing the results.
Overview
The analysis module takes the OpenFace data of a specific item of media and compares it to the chosen set of parameters. The results of this comparison are then forwarded to the reporting module.
Functionality
Each set of parameters contains reference values for each AU and degrees to which the uploaded media is allowed to deviate from it. This is expressed as a percentage.

The values for every AU have been determined by the OpenFace module prior to this.
The Analysis
The first step in the analysis is to retrieve the AU data calculated previously by the OpenFace service. This is done by providing the service with the correct container id and downloading the .csv file inside. The name of the .csv file has the parameter set and analysis type embedded, meaning no further data is required..
Once this file has been downloaded, the data is parsed and the AU values are stored in the database as an Action Unit Report. This allows the data to be tied to the final Analysis Report later down the line.
Now that all the data has been stored, the core analysis can be performed by comparing the stored AU values with the chosen parameter set.
For each AU, a calculation is made comparing the OpenFace data, parameter reference value and the desired deviation. These results are compiled in a list of tuples, with each tuple containing the action unit and a boolean relating to whether the AU value is within the allowed limits. Once the list has been completed it is forwarded to the function used to store the data.
Technical Specifications
Like the front-end, the analysis module is a Django application. It contains no templates as it has no user-facing functionality, but is accessed through REST calls from the Azure functions.
Parameter sets are retrieved from the database, while OpenFace data is retrieved from the BLOB storage.
Last updated