The processing and analysis of retinal fundus images is widely studied because many ocular fundus diseases such as diabetic retinopathy, hypertensive retinopathy, etc., can be diagnosed and treated based on the corresponding analysis results. The optic disc (OD), as the main anatomical structure of ocular fundus, its shape, border, size and pathological depression are very important auxiliary parameters for the diagnosis of fundus diseases. So the precise localization and segmentation of OD is important. Considering the excellent performance of deep learning in object detection and location, an automatic OD localization and segmentation algorithm based on Faster R-CNN and shape constrained level set is presented in this paper. First, Faster R-CNN+ZF model is used to locate the OD via a bounding box (B-box). Second, the main blood vessels in the B-box are removed by Hessian matrix if necessary. Finally, a shape constrained level set algorithm is used to segment the boundary of the OD. The localization algorithm was trained on 4000 images selected from Kaggle and tested on the MESSIDOR database. For the OD localization, the mean average precision (mAP) of 99.9% was achieved, with average time of 0.21s per image. The segmentation algorithm was tested on 120 images randomly selected from MESSIDOR database, achieving an average matching score of 85.4%.