Cardiovascular disease is a major global public health problem, and intelligent diagnostic approaches play an increasingly important role in the analysis of electrocardiograms (ECGs). Convenient wearable ECG devices enable the detection of transient arrhythmias and improve patient health by making it possible to seek intervention during continuous monitoring. We collected 658,486 wearable 12-lead ECGs, among which 164,538 were annotated, and the remaining 493,948 were without diagnostic. We present four data augmentation operations and a self-supervised learning classification framework that can recognize 60 ECG diagnostic terms. Our model achieves an average area under the receiver-operating characteristic curve (AUROC) and average F1 score on the offline test of 0.975 and 0.575. The average sensitivity, specificity and F1-score during the 2-month online test are 0.736, 0.954 and 0.468, respectively. This approach offers real-time intelligent diagnosis, and detects abnormal segments in long-term ECG monitoring in the clinical setting for further diagnosis by cardiologists.