The proposed approach considers the calculation of traveltimes on a coarse grid followed by neural network training for interpolating these traveltimes on a fine grid. Using the neural network approximation has two advantages: it reduces computational burden for complicated models (when numerical eikonal solvers should be used for traveltime computation on a fine grid), it also reduces memory requirements (as compared to storing all traveltimes computed on the fine grid). We derived the neural network architecture with a single hidden layer and performed the numerical tests, including the application of the proposed approach to the microseismic data imaging. The numerical test showed that for laterally inhomogeneous velocity model (2D) a neural network with 100 neurons on hidden layer provides a mean absolute error of about 2.7 ms and for thin-layered inhomogeneous velocity model (1D) a neural network with 4 neurons on hidden layer provides a mean absolute error of about 1 ms. The achieved accuracy is enough for the imaging objectives. Besides, the proposed approach allows to speed up the imaging performance by 4 times (2D) and by 20 times (1D) and also significantly reduce the memory for storage.