Dance is one of the significant avenues of releasing feelings, relieving internal stress, and conveying psychological moods in a free-body form. It is also a source of physical and mental regulation. This paper will identify first the main keypoints of infants and toddlers in dance-rhythm activities by entering images into a gesture recognition network. The body parts of infants and toddlers are further identified using the contour values of key-points based on a residual network, and the final categorization of dance movements is done using both key-point features classification and image classification. The identified dance actions are then fed into the Logical-Psychological Cognitive Model (LPCM) and, in combination with features derived using PoISAR images, they are used to assess cognitive-psychological significance and identify the mental state of infants and toddlers with various dance-rhythm postures. The simulation findings indicate that the ratio of intersections of the gesture-recognition estimation algorithm developed in this paper remains within [0.5, 1.0] with an average of 0.951, meaning that the suggested dance-gesture detection algorithm is very practical and applicable in detecting dance rhythms of infants and toddlers. Following the dance-rhythm intervention, the experimental group registered a high degree of improvement, and the overall physical self-esteem score increased to 77.07 from 67.22. It can be seen that psychological intervention with dance helps to increase the physical self-esteem of infants and toddlers, whereas dance rhythm has a positive influence on their mental health development and hence it is clearly pedagogical in nature.