A 1-D convolutional neural network (1-D CNN) is proposed to extract information collected from a U-shape single-mode-tapered seven core-single (STSS)-mode structure interferometer and demonstrated by measuring surrounding refractive index (RI) as a typical example of its application. Compared with the traditional dip/peak wavelength tracking method, the 1-D CNN method can effectively improve the accuracy of measurement through extracting full-spectrum information. The coefficient of determination ( $R^{2}$ ) of the RI predicted by 1-D CNN is as high as 0.992. At the same time, the effects of bandwidth and sampling points on the RI measurement accuracy are studied; by reducing the spectral sampling resolution and bandwidth, the prediction results are higher than 0.990 and 0.989, and the results show that the method of machine learning can adapt to the low sampling frequency and bandwidth. The proposed RI optical fiber sensing system has good application potential in medical and environmental monitoring fields.