Accurate crowd counting in congested scenes is still challenging, and its inference speed is also essential in intelligent edge devices. To tackle this issue, we propose a novel lightweight scale-aware network (LSANet) for high-accuracy real-time crowd counting, which consists of four structures: local extractor (LE), scale feature extraction module (SFEM), scale feature fusion module (SFFM), and density map regressor (DMR). Specifically, we devise the SFEM and SFFM carefully to reinforce the learning capability of scale representation, which significantly improves the counting accuracy. Besides, the multi-level intersection-over-union (MIoU) loss function is proposed to reduce background false recognition and estimation errors. Extensive experiments on four mainstream datasets demonstrate that our method achieves the optimal trade-off between effectiveness and efficiency compared with previous lightweight methods.
We propose a semi-supervised network for wide-angle portraits correction. Wide-angle images often suffer from skew and distortion affected by perspective distortion, especially noticeable at the face regions. Previous deep learning based approaches need the ground-truth correction flow maps for training guidance. However, such labels are expensive, which can only be obtained manually. In this work, we design a semi-supervised scheme and build a high-quality unlabeled dataset with rich scenarios, allowing us to simultaneously use labeled and unlabeled data to improve performance. Specifically, our semi-supervised scheme takes advantage of the consistency mechanism, with several novel components such as direction and range consistency (DRC) and regression consistency (RC). Furthermore, different from the existing methods, we propose the Multi-Scale Swin-Unet (MS-Unet) based on the multi-scale swin transformer block (MSTB), which can simultaneously learn short-distance and long-distance information to avoid artifacts. Extensive experiments demonstrate that the proposed method is superior to the state-of-the-art methods and other representative baselines. The source code and dataset are available at https://github.corn/megvii-research/PortraitsCorrection
The fast JPEG image compression algorithm is a requisite in many applications such as high-speed video measurement systems and digital cinema. Many existing methods have implemented the JPEG compression in parallel based on GPU except for entropy coding, which is a variable-length coding method and seems like a better fit for sequential implementation. However, entropy coding is an essential part of the JPEG compression system and typically takes up a large proportion of the time when implemented on the CPU. To tackle this problem, we propose an efficient parallel entropy coding (EPEnt) method for parallel JPEG compressing. The proposed method conducts entropy coding in three parallel steps: coding, shifting, and stuffing. Specifically, according to the different characteristics of image components, we devise thread-based and warp-based functions in the coding stage to further improve the efficiency under guaranteeing image quality, respectively. We apply the proposed method to the parallel JPEG compression system and evaluate the performance based on compute unified device architecture (CUDA). The experimental results demonstrate that compared with sequential implementation, the maximum speedup ratio of entropy coding can reach 39 times without affecting compressed images quality. Meanwhile, the whole JPEG compression process efficiency increases by at least 28% compared with state-of-the-art parallel methods in terms of speedup ratio.
为了快速计算分析利用视频测量方法测得的高速风洞试验密度场在扰动流场作用下的实验数据,针对密度场的数值求解问题,经过光线偏折理论分析密度场得到的二阶偏微分方程,对其研究实现了CPU串行有限元法求解.在此基础上提出了基于GPU的快速有限元求解密度场的方法,该方法经过对串行有限元法求解过程效率分析后,将耗时的神经网络拟合、总刚度矩阵和总载荷向量的求解进行了基于GPU的并行加速.实验结果表明:在精度满足实际工程要求的前提下,相对于CPU串行求解方法,所提方法可大大提高求解效率,且随着网格剖分成倍加密,其加速比成倍增加.
Crowd counting aims to count the number of pedestrians in an image or a video. Currently, scale variations in crowd counting are inevitable and challenging in practice. Besides, for the crowd counting task, there is only a small amount of annotated data available. It can be seen from previous methods of crowd counting and object detection that the two tasks have similar attention areas. However, existing methods in crowd counting generally ignore the similarities and specialties between the crowd counting task and the object detection task. In this paper, in order to solve the above challenges, we propose an adversarial scale-adaptive neural network (ASANet), consisting of three branches. First, a private branch for the crowd counting task concentrates on generating high-quality density maps. Second, another private branch for the object detection task aims to correctly detect and recognize objects. Third, we design a common branch to learn the similar attention area of the two tasks and assist crowd counting. Experimental results demonstrate an outstanding performance of the ASANet over state-of-the-art methods on three public datasets (ShanghaiTech, UCF_CC_50, and UCF_QNRF).
With the improvement of public security awareness, video anomaly detection has become an indispensable demand in surveillance videos. To improve the accuracy of video anomaly detection, this paper proposes a novel two-stream spatial-temporal architecture called Two-Stream Deep Spatial-Temporal Auto-Encoder (Two-Stream DSTAE), which is composed of a spatial stream DSTAE and a temporal stream DSTAE. Firstly, the spatial stream extracts appearance characteristics whereas the temporal stream extracts the motion patterns, respectively. Then, based on the novel policy joint reconstruction error, this model fuses the spatial stream and the temporal stream to extract spatial-temporal characteristics to detect anomalies. Furthermore, since the optical flow is invariant to appearances such as color or light, we introduce optical flow to enhance the capability of extracting continuity between adjacent frames and inter-frame motion information. We demonstrate the accuracy of the proposed method on the publicly available standard datasets: UCSD, Avenue and UMN datasets. Our experiments demonstrate high accuracy, which is superior to the state-of-the-art methods.
Recently, crowd counting has drawn widespread attention in computer vision, but it is extremely challenging because of the varying scales and densities. Many existing methods focus on improving the multi-scale representation by utilizing multi-column or multi-branch architectures with different kernel sizes. However, such networks cannot extract the feature maps with large receptive fields due to limitation of depth. In addition, the importance of utilizing the multi-level feature information in a deep network is ignored. In this paper, we propose a multi-scale and multi-level features aggregation network (MFANet) for accurate and efficient crowd counting, and it can be trained by end-to-end. A vital component of the network is the scale and level aggregation module (SLAM), which can extract multi-scale features and make full use of multi-level feature information for more accurate estimation. When six SLAMs are stacked together and applied to our network, our method can achieve the best performance. Furthermore, we introduce a new loss function called normalized Euclidean loss (NEL) to balance the contribution of all samples to network training. To demonstrate the performance of the proposed method, extensive experiments are conducted on four benchmark crowd counting datasets, including ShanghaiTec Part A/B, UCF-CC-50, Mall, and UCF-QNRF. Experimental results show that our MFANet achieves state-of-the-art performance in crowd counting and crowd localization.
某流场中,密度投影场与扰动引起的光线偏移角之间满足泊松方程的关系,且该泊松方程的源项是一系列离散的偏移角,无法利用现有方法直接求解.在有限元法的基础上,利用神经网络拟合源项中偏折角与采样坐标的关系,得到剖分网格点上的源项;同时,针对神经网络的加入使得有限元法中单元载荷向量的求解过于耗时的问题,在求解源项时,论文将三角单元整体预测的二重积分表达式近似替换为三角单元结点预测的常数表达式.仿真实验表明,引入神经网络拟合偏折角,相对于传统的插值方法,可以取得更高精度的结果;而且在相同误差下,提出的算法大大提升了运算速度.将该算法应用到真实流场中,得到的该密度投影场的特性与搭建的真实环境的结果相似,进一步说明所提算法的有效性.
In the wind tunnel flow field, the relationship between the density projection field, caused by disturbance, and the offset angle of light meets the Poisson equation. However, the source term of the Poisson equation is composed of a series of measured offset angles, which makes it can not be solved effectively by the existing methods. On the basis of the finite element method (FME), we established the fitting formula between the offset angles in the source terms and their corresponding coordinates by employing the Genetic algorithms and back-propagation (GA-BP) neural network. Meanwhile, when the element load vectors were solved, the double integral expression of the entire triangle element prediction was approximately replaced by the constant expression of the triangle vertex element prediction. Simulation experiments demonstrate that compared with the traditional interpolation, the neural network can achieve higher fitting precision. And the proposed algorithm greatly improves the operation speed under the same solution error. By applying the proposed algorithm to the real flow field, the obtained features of the density field are similar to those obtained in the real environment. These imply that the proposed method provides a new useful tool for the study of the density projection field.