| Crowd counting and crowd density detection are important security techniques for public safety in shopping malls,subway stations,tourist attractions and other places to avoid trampling and respond to emergencies such as fires.In real application scenarios,as crowd density increases,the detection of crowd density is seriously affected by perspective distortion,drastic scale changes,and high similarity between pedestrians and background.In this thesis,we address the crowd density detection problem with the presence of scale variation and background clutter,and provide an in-depth discussion of crowd counting and crowd density detection algorithms based on convolutional neural networks.The main work of this thesis are as follows.(1)A crowd counting algorithm based on multi-level information aggregation is proposed to the problem of crowd scale change in natural scenes.Each layer of the feature map in the feature extraction network corresponds to a different scale feature.The low-level network contains more detailed detail information,which is beneficial to form a density map of high-density scenes,while the high-level network contains more semantic information,which is beneficial to distinguish the human head from the background noise.To improve the feature representation capability and scale diversity,the algorithm introduces a multi-level information aggregation network in the feature extraction stage to fuse the high-level semantic information with the bottom-level detail information in a bottom-up manner,achieve low-level feature reuse through cross-layer connections,and use multiple levels of fused features to detect crowds with large scale variations so that key features are effectively retained to extract more crowd features of different scales.Experimental results of several mainstream datasets shows that the proposed algorithm effectively mitigates the effects of drastic changes in population scale and improves the accuracy of counts.(2)For the problem of uneven distribution of crowds and interference of background clutter and noise in real scenes,we propose a deep crowd counting algorithm based on the collaboration with multiple attention mechanisms.The algorithm introduces an attention mechanism in the last three layers of the feature encoding phase to achieve enhancement of network features and suppress background interference.Spatial attention is introduced to enhance the underlying features of the network,and channel attention are added to dynamically learn weights between each channel,enhance important channels,and allocate attention adaptively between different input features to effectively improve the performance of the network.To construct a multi-attention mechanism,the channel attention network is connected and fused with the spatial attention network of parallel,so that the network pays more attention to the human head region and reduces the interference from background objects.Experimental results from multiple datasets show that the proposed multi-attention collaborative-based deep crowds counting algorithm can effectively combat background interference,attenuate the effect of uneven crowd distribution,and significantly improve the accuracy of crowd counting. |