Carbon dioxide injection can help solve two issues in shale reservoir production. Firstly, it can reduce carbon emissions while, secondly, improving unconventional reservoir recovery. There are many controlling factors for CO2 injection to enhance oil recovery in shale reservoirs, and the effect of field implementation varies greatly. The key to popularizing this extraction technology is determining the main controlling factors of CO2 displacement efficiency. Using CO2 shale displacement laboratory results, the grey correlation analysis method was used to determine the main controlling factors affecting core oil displacement efficiency, such as shale reservoir physical parameters (rock compressibility, porosity, median pore size, matrix permeability, TOC, and oil saturation) and engineering parameters (soaking time and injection pressure). The genetic algorithm (GA) was introduced to optimize the backpropagation (BP) neural network to construct the prediction model of the CO2 indoor displacement experiments in shale cores. The results showed that the injection pressure among the engineering parameters, the CO2 soaking time among the gas injection parameters, and the porosity among the shale physical parameters were the main controlling factors affecting the oil displacement efficiency. The prediction accuracy of the genetic neural network model improved, and the coefficient of determination (R2) reached 0.983. Compared with the conventional neural network model, the mean absolute error (MAE) was reduced by 30%, the root mean square error (RMSE) was reduced by 46%, and the R2 increased by 11%. Optimizing the learning and training of the prediction model significantly reduces the cost of laboratory experiments. The deep-learning model completed by training can intuitively show the degree of influence of input parameters on output parameters, providing a theoretical basis for the study of CO2 displacement mechanisms in shale reservoirs.