It is economical and efficient to use existing natural gas pipelines to transport hydrogen. The fast and accurate prediction of mixing uniformity of hydrogen injection in natural gas pipelines is important for the safety of pipeline transportation and downstream end users. In this study, the computational fluid dynamics (CFD) method was used to investigate the hydrogen injection process in a T-junction natural gas pipeline. The coefficient of variation (COV) of a hydrogen concentration on a pipeline cross section was used to quantitatively characterize the mixing uniformity of hydrogen and natural gas. To quickly and accurately predict the COV, a deep neural network (DNN) model was constructed based on CFD simulation data, and the main influencing factors of the COV including flow velocity, hydrogen blending ratio, gas temperature, flow distance, and pipeline diameter ratio were taken as input nodes of the DNN model. In the model training process, the effects of various parameters on the prediction accuracy of the DNN model were studied, and an accurate DNN architecture was constructed with an average error of 4.53% for predicting the COV. The computational efficiency of the established DNN model was also at least two orders of magnitude faster than that of the CFD simulations for predicting the COV.