SoftwareX (May 2024)
PyCinemetrics: Computational film studies tool based on deep learning and PySide2
Abstract
Although computer vision offers ample possibilities, there is currently a lack of general film measurement software. Here, we propose a software called PyCinemetrics, which is a computational film studies tool offering five functions that utilize deep learning and PySide2 to deconstruct the visual style of films. It uses TransNetV2 to divide a film into shot-frames, allowing for the exploration of Average Shot Length (ASL) and pace. The tool also extracts main colors from shot-frames using K-Means. Furthermore, it can extract movie subtitles using EasyOcr to obtain dialogue. Additionally, PyCinemetrics utilizes object detection based on VGG19 to identify metaphorical props and objects. By detecting the proportion of skeletal points occupied in the frame using OpenPose, it indirectly determines the shot scale. Finally, PyCinemetrics was integrated and implemented using PySide2. A group of classic films was analyzed using PyCinemetrics, demonstrating its accuracy and efficiency in frame analysis.