The existing spectrum sensing methods mostly make decisions using model-driven test statistics, such as energy and eigenvalues. A weakness of these model-driven methods is the difficulty in accurately modeling for practical environment. In contrast to the model-driven approach, in this paper, we use a deep neural network to automatically learn features from data itself, and develop a data-driven detection approach. Inspired by the powerful capability of convolutional neural network (CNN) in extracting features of matrix-shaped data, we use the sample covariance matrix as the input of CNN, proposing a novel covariance matrix-aware CNN-based detection scheme, which consists of offline training and online detection. Different from the existing deep learning-based detection methods which replace the whole detection system by an end-to-end neural network, in this work, we use CNN for offline test statistic design and develop a practical threshold-based online detection mechanism. Specially, according to the maximum a posteriori probability (MAP) criterion, we derive the cost function for offline training in the spectrum sensing model, which guarantees the optimality of the designed test statistic. Simulation results have shown that whether the PU signals are independent or correlated, the detection performance of the proposed method is close to the optimal bound of estimator-correlator detector. Particularly, when the PU signals are correlated with a correlation coefficient 0.7, the probability of detection of the proposed method outperforms the conventional maximum eigenvalue detection method by nearly 7.5 times at SNR = -14dB.