The attenuation effect can influence the precision of inversion of Earth's physical properties when solving geophysical inverse problems utilizing seismic data. Therefore using the viscoelastic acoustic wave equation is more suitable for the actual situation. In this paper, based on seismic forward modeling considering the attenuation effect in the frequency-space domain, the inversion algorithm with inverse scattering based on viscoelastic acoustic equation is applied in the frequency domain to reconstruct seismic velocity distribution. Real or complex velocity is used individually in the inversion process depending on whether the earth attenuation effect is considered. Meanwhile the regularization of inversion parameter's total variation makes this inversion approach more stable. Frequency-divided inversion strategy is adopted, the lower frequency inversion result is set as the background model of higher frequency inversion, and the background model remains constant during the inversion process for a particular frequency. So this inversion method does not need to reconstruct the forward operator in each iteration, which makes it more efficient. In order to improve the efficiency of inversion calculation further, the MPI parallel computing strategy is used in the procedure of inversion. In a 2D numerical example, the inversion algorithm is applied with and without considering the attenuation effect respectively. The results from the former approach is closer to the real velocity model, while the latter cannot match the real model. This algorithm can achieve high-resolution velocity reconstruction results for complex geological models at shallow and middle layers, and can provide accurate velocity information for other seismic data processing. While the inversion resolution is not ideal for a deep layer due to the attenuation of seismic energy.