# Student Behavior Recognition in Classroom Based on Deep Learning
###### Abstract  
With the widespread application of information technology in education, the real-time detection of student behavior in the classroom has become a key issue in improving teaching quality. This paper proposes a Student Behavior Detection (SBD) model that combines YOLOv5, the Contextual Attention (CA) mechanism and OpenPose, aiming to achieve efficient and accurate behavior recognition in complex classroom environments. By integrating YOLOv5 with the CA attention mechanism to enhance feature extraction capabilities, the model's recognition performance in complex backgrounds, such as those with occlusion, is significantly improved. In addition, the feature map generated by the improved YOLOv5 is used to replace VGG-19 in OpenPose, which effectively improves the accuracy of student posture recognition. The experimental results demonstrate that the proposed model achieves a maximum mAP of 82.1% in complex classroom environments, surpassing Faster R-CNN by 5.2 percentage points and YOLOv5 by 4.6 percentage points. Additionally, the F1 score and R value of this model exhibit clear advantages over the other two traditional methods. This model offers an effective solution for intelligent classroom behavior analysis and the optimization of educational management. deep learning; behavior detection; YOLOv5; students' classroom behavior +
Footnote †: journal:  
details of student behavior. Although the OpenPose algorithm performs well in human pose recognition, it still faces challenges when applied to long-distance and complex backgrounds [6]. For example, [PERSON] et al. [7] proposed an enhanced deep-learning framework aimed at improving posture recognition accuracy in complex backgrounds. Their research demonstrated that incorporating multi-scale feature fusion significantly enhances the detection of key points in such environments. However, this method still faces limitations when addressing large-scale variations. Similarly, [PERSON] et al. [8] investigated the use of body-cropping augmentation (BCA) for long-distance posture recognition. Through BCA, they successfully improved the model's robustness in long-distance scenarios. However, much of the current research emphasizes behavior recognition in static scenes, presenting challenges for effectively adapting these methods to complex and dynamic classroom environments. Existing systems struggle with complex scenarios, such as occlusion and lighting variations. To address the aforementioned challenges, this paper introduces a novel model called Student Behavior Detection (SBD). This model is designed to accurately detect the behavioral characteristics and real-time activities of students within the classroom environment. By doing so, it overcomes the limitations of traditional detection methods and fosters intelligent advancement of educational technology. Specifically, the model leverages a hybrid deep neural network that integrates the object detection capabilities of YOLOv5, the feature enhancement abilities of the Coordinate Attention (CA) mechanism, and the pose recognition capabilities of OpenPose. This integration enables comprehensive detection of students' classroom behavior. The main contribution of this study is concluded as follows:  
1. We proposed a novel student behavior detection model specifically designed for complex classroom environments, which integrates YOLOv5, the CA mechanism, and OpenPose. 2. By combining the strengths of YOLOv5 and the CA attention mechanism, we constructed a hybrid neural network model. The CA module is integrated into the Backbone of YOLOv5 (referred to as the newly constructed network YOLOv5-A), replacing all convolutional modules with attention module structures to enrich the semantic information in the prediction layer and enhance the detection accuracy of small targets. OpenPose is then utilized based on the newly generated feature maps from YOLOv5-A, replacing the original VGG-19, which not only improves the accuracy of human posture recognition but also reduces computational costs.