DOI QR코드

DOI QR Code

Full Waveform Inversion Using Automatic Differentiation

자동 미분을 이용한 전파형 역산

  • Wansoo, Ha (Department of Energy Resources Engineering, Pukyong National University)
  • 하완수 (부경대학교 에너지자원공학과)
  • Received : 2022.07.14
  • Accepted : 2022.11.07
  • Published : 2022.11.30

Abstract

Automatic differentiation automatically calculates the derivatives of a function using the chain rule once the forward operation of a function is defined. Given the recent development of computing libraries that support automatic differentiation, many researchers have adopted automatic differentiation techniques to solve geophysical inverse problems. We analyzed the advantages, disadvantages, and performances of automatic differentiation techniques using the gradient calculations of seismic full waveform inversion objective functions. The gradients of objective functions can be expressed as multiplications of the derivatives of the model parameters, wavefields, and objective functions using the chain rule. Using numerical examples, we demonstrated the speed of analytic differentiation and the convenience of complex gradient calculations for automatic differentiation. We calculated derivatives of model parameters and objective functions using automatic differentiation and derivatives of wavefields using analytic differentiation.

자동 미분은 컴퓨터를 이용한 미분 계산시 함수의 전방향 연산만 정의하면 연쇄법칙을 이용해 함수의 미분을 자동으로 계산해주는 기능이다. 최근 자동 미분을 지원하는 계산 라이브러리들의 발달에 따라 지구 물리 역산 문제에 자동 미분 기술을 도입하는 사례가 증가하고 있다. 본 연구에서는 탄성파 탐사 전파형 역산 목적함수의 그래디언트 계산시 자동 미분을 도입하였을 때의 장단점과 성능을 분석하였다. 목적함수의 그래디언트 계산은 연쇄법칙을 이용해 매개변수 미분, 파동장 미분과 목적함수 미분의 곱으로 나타낼 수 있다. 수치 예제를 통해 매개변수 미분과 목적함수 미분 계산은 자동 미분으로 수행하고 파동장 미분은 해석적 방법으로 수행함으로써 해석적 미분의 장점인 빠른 성능과 자동 미분의 장점인 복잡한 그래디언트 계산의 편리성을 함께 얻을 수 있음을 보였다.

Keywords

Acknowledgement

이 논문은 부경대학교 자율창의학술연구비(2021년)에 의하여 연구되었음.

References

  1. Abadi, M., Barham, P., Chen, J., Chen, Z., Davis, A., Dean, J., Devin, M., Ghemawat, S., Irving, G., Isard, M., Kudlur, M., Levenberg, J., Monga, R., Moore, S., Murray, D., Steiner, B., Tucker, P., Vasudevan, V., Warden, P., Wicke, M., Yu, Y., and Zheng, X., 2016, TensorFlow: A system for large-scale machine learning, 12th USENIX Symposium on Operating Systems Design and Implementation, 265-283. https://www.usenix.org/system/files/conference/osdi16/osdi16-abadi.pdf
  2. Anderson, J. E., Tan, L., and Wang, D., 2012, Time-reversal checkpointing methods for RTM and FWI, Geophysics, 77, S93-S103. https://doi.org/10.1190/geo2011-0114.1
  3. Baydin, A., Pearlmutter, B., Radul, A., and Siskind, J., 2018, Automatic differentiation in machine learning: A survey, Journal of Machine Learning Research, 18, 1-43. https://www.jmlr.org/papers/volume18/17-468/17-468.pdf
  4. Cao, D., and Liao, W., 2015, A computational method for full waveform inversion of crosswell seismic data using automatic differentiation, Computer Physics Communications, 188, 47-58. doi: 10.1016/j.cpc.2014.11.002
  5. Deepwave, 2022, https://github.com/ar4/deepwave (July 13, 2022 Accessed)
  6. Diffsharp, 2022, https://diffsharp.github.io (July 13, 2022 Accessed)
  7. Esser, E., Guasch, L., Leeuwen, T. van, Aravkin, A. Y., and Herrmann, F. J., 2018, Total variation regularization strategies in full-waveform inversion, SIAM Journal on Imaging Sciences, 11, 376-406. https://doi.org/10.1137/17M111328X
  8. Giering, R., Kaminski, T., and Slawig, T., 2005, Generating efficient derivative code with TAF adjoint and tangent linear Euler flow around an airfoil, Future Generation Computer Systems, 21, 1345-1355. https://doi.org/10.1016/j.future.2004.11.003
  9. Griewank, A., 1992, Achieving logarithmic growth of temporal and spatial complexity in reverse automatic differentiation, Optimization Methods and Software Optimization Methods & Software, 1, 35-54. https://doi.org/10.1080/10556789208805505
  10. Griewank, A., 1989, On automatic differentiation, Kluwer Academic Publishers. http://softlib.rice.edu/pub/CRPC-TRs/reports/CRPC-TR89003.pdf
  11. Griewank, A., and Walther, A., 2000, Algorithm 799: Revolve: An implementation of checkpointing for the reverse or adjoint mode of computational differentiation, ACM Transactions on Mathematical Software, 26, 19-45. https://doi.org/10.1145/347837.347846
  12. Hascoet, L., and Pascual, V., 2013, The Tapenade automatic differentiation tool: Principles, model, and specification, ACM Transactions on Mathematical Software, 39(3), Article 20. https://doi.org/10.1145/2450153.2450158
  13. Ha, W., 2021, Building software research environment using Linux container and version control system, Geophysics and Geophysical Exploration, 24(2), 45-52. https://doi.org/10.7582/GGE.2021.24.2.45
  14. He, Q., and Wang, Y., 2021, Reparameterized full-waveform inversion using deep neural networks, Geophysics, 86, V1-V13. https://doi.org/10.1190/geo2019-0382.1
  15. Kingma, D. P., and Ba, J., 2015, Adam: A method for stochastic optimization, arXiv 1412.6980v9. https://doi.org/10.48550/arXiv.1412.6980
  16. Lee, D., Lee, J., Shin, C., Shin, S., and Chung, W., 2022, Elastic full-waveform inversion using both the multiparametric approximate hessian and the discrete cosine transform, IEEE Transactions on Geoscience and Remote Sensing, 60, 5903510. https://ieeexplore.ieee.org/abstract/document/9509351
  17. Li, D., Xu, K., Harris, J. M., and Darve, E., 2020, Coupled time-Lapse full-Waveform inversion for subsurface flow problems using intrusive automatic differentiation, Water Resources Research, 56(8), e2019WR027032. https://doi.org/10.1029/2019WR027032
  18. Marfurt, K., 1984, Accuracy of finite-difference and finite-element modeling of the scalar and elastic wave equations, Geophysics, 49, 533-549. https://doi.org/10.1190/1.1441689
  19. Margossian, C. C., 2019, A review of automatic differentiation and its efficient implementation, WIREs Data Mining and Knowledge Discovery, 9, e1305. https://doi.org/10.1002/widm.1305
  20. Naumann, U., and Riehme, J., 2005, A differentiation-enabled Fortran 95 compiler. ACM Transactions on Mathematical Software, 31(4), 458-474. https://doi.org/10.1145/1114268.1114270
  21. Nguyen, B. D., and McMechan, G. A., 2015, Five ways to avoid storing source wavefield snapshots in 2D elastic prestack reverse time migration, Geophysics, 80, S1-S18. https://doi.org/10.1190/geo2014-0014.1
  22. Nguyen, B. D., and McMechan, G. A., 2013, Excitation amplitude imaging condition for prestack reverse-time migration, Geophysics, 78, S37-S46. https://doi.org/10.1190/geo2012-0079.1
  23. Paszke, A., Gross, S., Chintala, S., Chanan, G., Yang, E., DeVito, Z., Lin, Z., Desmaison, A., Antiga, L., and Lerer, A., 2017, Automatic Differentiation in PyTorch, 31st Conference on Neural Information Processing Systems, Long Beach, CA, USA. https://openreview.net/forum?id=BJJsrmfCZ
  24. Plessix, R.-E., 2006, A review of the adjoint-state method for computing the gradient of a functional with geophysical applications, Geophysical Journal International, 167, 495-503. https://adsabs.harvard.edu/full/2006GeoJI.167..495P https://doi.org/10.1111/j.1365-246X.2006.02978.x
  25. Reddi, S. J., Kale, S., and Kumar, S., 2018, On the convergence of adam and beyond, International Conference on Learning Representations, International Conference on Learning Representations. https://openreview.net/forum?id=ryQu7f-RZ
  26. Richardson, A., 2018, Seismic full-waveform inversion using deep learning tools and techniques, arXiv 1801.07232v2. https://doi.org/10.48550/arXiv.1801.07232
  27. Sambridge, M., Rickwood, P., Rawlinson, N., and Sommacal, S., 2007, Automatic differentiation in geophysical inverse problems, Geophysical Journal International, 170, 1-8. https://doi.org/10.1111/j.1365-246X.2007.03400.x
  28. Shen, X., and Clapp, R. G., 2015, Random boundary condition for memory-efficient waveform inversion gradient computation, Geophysics, 80, R351-R359. https://doi.org/10.1190/geo2014-0542.1
  29. Shin, C., and Ha, W., 2017, Accumulated energy norm for full waveform inversion of marine data, Journal of Applied Geophysics, 147, 91-101. https://doi.org/10.1016/j.jappgeo.2017.10.005
  30. Symes, W. W., 2007, Reverse time migration with optimal checkpointing, Geophysics, 72, SM213-SM221. https://doi.org/10.1190/1.2742686
  31. Tarantola, A., 1984, Inversion of seismic reflection data in the acoustic approximation, Geophysics, 49, 1259-1266. https://library.seg.org/doi/10.1190/1.1441754
  32. TensorBoard, 2022, https://www.tensorflow.org/tensorboard (July 13, 2022 Accessed)
  33. TorchWI, 2022, https://github.com/pkgpl/TorchWI (July 13, 2022 Accessed)
  34. Utke, J., Naumann, U., Fagan, M., Tallent, N., Strout, M., Heimbach, P., Hill, C., and Wunsch, C., 2008, OpenAD/F: A modular open-source tool for automatic differentiation of Fortran codes, ACM Transactions on Mathematical Software, 34(4), Article 18. https://www.mcs.anl.gov/uploads/cels/papers/P1230.pdf
  35. Versteeg, R., 1994, The Marmousi experience: Velocity model determination on a synthetic complex data set, Leading Edge, 13, 927-936. doi: 10.1190/1.1437051
  36. Virieux, J., and Operto, S., 2009, An overview of full-waveform inversion in exploration geophysics, Geophysics, 74, WCC1-WCC26. https://doi.org/10.1190/1.3238367
  37. Vlasenko, A. V., Kohl, A., and Stammer, D., 2016, The efficiency of geophysical adjoint codes generated by automatic differentiation tools, Computer Physics Communications, 199, 22-28. https://doi.org/10.1016/j.cpc.2015.10.008
  38. Wengert, R. E., 1964, A simple automatic derivative evaluation program, Communications of the ACM, 7, 463-464. https://doi.org/10.1145/355586.364791
  39. Wu, Y., and McMechan, G.A., 2019, Parametric convolutional neural network-domain full-waveform inversion, Geophysics, 84, R881-R896. https://doi.org/10.1190/geo2018-0224.1
  40. Yang, P., Gao, J., and Wang, B., 2014, RTM using effective boundary saving: A staggered grid GPU implementation, Computers & Geosciences, 68, 64-72. https://doi.org/10.1016/j.cageo.2014.04.004
  41. Zhu, W., Xu, K., Darve, E., and Beroza, G.C., 2021, A general approach to seismic inversion with automatic differentiation, Computers & Geosciences, 151, 104751. https://doi.org/10.1016/j.cageo.2021.104751