As a key part of the method of improving traffic capacity, traffic flow prediction is becoming a research hot-spot of traffic science and intelligent technology, in which the accuracy of traffic flow prediction is particularly concerned. In this paper, a novel fuzzy-based convolutional neural network (F-CNN) method is proposed to predict the traffic flow more accurately, in which a fuzzy approach has been applied to represent the traffic accident features when introducing uncertain traffic accidents information into the CNN at the first time. First, for the sake of extracting the spatial-temporal characteristics of the traffic flow data, this paper divides the whole area into small blocks of 32 × 32 and constructs three trend sequences with inflow and outflow types. Second, uncertain traffic accident information is generated from the real traffic flow data by utilizing a fuzzy inference mechanism. Finally, the F-CNN model is realized to train the internal information of the trend sequence, the uncertain traffic accident information, and the external information. Moreover, pre-training and fine-tuning strategies are efficiently developed to learn the parameters of the F-CNN. At last, the real Beijing taxicab trajectory and the meteorology datasets are employed to show that the proposed method has superior performance compared with the state-of-the-art approaches.INDEX TERMS Traffic flow prediction, traffic accident information, fuzzy inference system (FIS), convolutional neural network (CNN), fuzzy-based convolutional neural network (F-CNN).