Premature Ventricular Contractions (PVCs) are a common type of cardiac arrhythmia that can be life-threatening if left untreated. Using deep learning methods to address challenges such as data imbalance, inaccurate ECG segment labeling, and noise interference in PVC detection remains a significant endeavor. This study presents a dual-path CNN network (WACNN) designed based on wavelet decomposition and attention mechanisms for detecting PVCs from single-lead electrocardiograms (ECGs). All ECG recordings are firstly resampled to 256 Hz. The R-peak positions detected using the Pan-Tompkins method are firstly used to extract a 256 points fixed-duration as training set A, and then used to extract two complete RR intervals as another training set (B). Subsequently, all segments in training set B are resampled to 512 points, resulting in a rescaled training set C. Set B and set C are fed into the model through two separate paths for training. The ratio of the original segment length in B to 512 is considered as a critical infection feature (heart rate feature) for PVC detection in the model. The proposed model is trained on 11 recordings from the MIT-BIH Arrhythmia Database (MITAD) and validated on another 11 recordings, excluding pacemaker data. Testing is conducted on the remaining 22 recordings. On the test dataset, the model achieved a precision of 95.41%, recall of 98.72%, F1 score of 97.04%, and overall accuracy of 99.63%, outperforming most existing methods. The experimental results validate the effectiveness of the proposed approach, which shows promise for enhancing PVC detection in long-term ECG monitoring scenarios.