×

Automated linear solver selection for simulation of multiphysics processes in porous media. (English) Zbl 1539.76011

Summary: Porous media processes involve various physical phenomena such as mechanical deformation, transport, and fluid flow. Accurate simulations must capture the strong couplings between these phenomena. Choosing an efficient solver for a multiphysics problem usually entails the decoupling into subproblems related to separate physical phenomena. Then, the suitable solvers for each subproblem and the iteration scheme must be chosen. Finally, the numerical parameters of the solvers must be optimized. Theoretical considerations often allow us to come up with several robust linear solvers for a given problem, but they cannot guide us further in seeking the most efficient linear solver configuration because its performance depends on hardware, software and the driving forces of the simulated model. As a further complication, these driving forces can vary with time within one simulation, causing the most efficient linear solver configuration to change. Switching a solver with respect to the dominant process can be beneficial, but the threshold of when to switch solver is unclear and complicated to analyze. We address this challenge by developing a machine learning framework that automatically searches for the optimal solver for a given multiphysics simulation setup, based on statistical data from previously solved problems. For a series of problems, exemplified by successive time steps in a time-dependent simulation, the framework updates and improves its decision model online during the simulation. We describe the solver selection algorithm, present examples of how the solver selector tunes the solver during the simulation, and show how it outperforms preselected state-of-the-art solvers for test problem setups. The examples are based on simulations of poromechanics and simulations of flow and transport. For the quasi-static linear Biot model, we demonstrate automated tuning of numerical solver parameters by showing how the L-parameter of the so-called Fixed-Stress preconditioner can be optimized. Motivated by a test example where the main heat transfer mechanism changes between convection and diffusion, we also discuss how the solver selector can dynamically switch solvers when the dominant physical phenomenon changes with time.

MSC:

76-10 Mathematical modeling or simulation for problems pertaining to fluid mechanics
76S05 Flows in porous media; filtration; seepage
65F08 Preconditioners for iterative methods
65C20 Probabilistic models, generic numerical methods in probability and statistics
65K10 Numerical optimization and variational techniques
65M70 Spectral, collocation and related methods for initial value and initial-boundary value problems involving PDEs
74F10 Fluid-solid interactions (including aero- and hydro-elasticity, porosity, etc.)

References:

[1] Settari, A.; Mounts, F. M., A coupled reservoir and geomechanical simulation system, SPE J., 3, 03, 219-226, 1998
[2] White, J.; Castelletto, N.; Tchelepi, H., Block-partitioned solvers for coupled poromechanics: A unified framework, Comput. Methods Appl. Mech. Engrg., 303, 55-74, 2016 · Zbl 1425.74497
[3] Both, J. W.; Borregales, M.; Nordbotten, J.; Kumar, K.; Radu, F., Robust fixed stress splitting for Biot’s equations in heterogeneous media, Appl. Math. Lett., 68, 101-108, 2017 · Zbl 1383.74025
[4] Kim, J.; Tchelepi, H.; Juanes, R., Stability and convergence of sequential methods for coupled flow and geomechanics: Drained and undrained splits, Comput. Methods Appl. Mech. Engrg., 23, 200, 2094-2116, 2011 · Zbl 1228.74106
[5] Kim, J.; Tchelepi, H.; Juanes, R., Stability and convergence of sequential methods for coupled flow and geomechanics: Fixed-stress and fixed-strain splits, Comput. Methods Appl. Mech. Engrg., 13, 200, 1591-1606, 2011 · Zbl 1228.74101
[6] Mikelić, A.; Wheeler, M. F., Convergence of iterative coupling for coupled flow and geomechanics, Comput. Geosci., 17, 455-461, 2013 · Zbl 1392.35235
[7] Storvik, E.; Both, J.; Kumar, K.; Nordbotten, J.; Radu, F., On the optimization of the fixed-stress splitting for Biot’s equations, Internat. J. Numer. Methods Engrg., 120, 179-194, 2018 · Zbl 07859732
[8] Trangenstein, J.; Bell, J., Mathematical structure of compositional reservoir simulation, SIAM J. Sci. Stat. Comput., 10, 5, 817-845, 1989 · Zbl 0672.76103
[9] Wallis, J., Incomplete Gaussian elimination as a preconditioning for generalized conjugate gradient acceleration, (Proc. of SPE Reservoir Simulation Symposium, 1983), SPE-12265-MS
[10] Wallis, J. R.; Kendall, R. P.; Little, T. E., Constrained residual acceleration of conjugate residual methods, (Proc. of SPE Reservoir Simulation Symposium, 1985), SPE-13536-MS
[11] Lacroix, S.; Vassilevski, Y.; Wheeler, J.; Wheeler, M., Iterative solution methods for modeling multiphase flow in porous media fully implicitly, SIAM J. Sci. Comput., 25, 3, 905-926, 2003 · Zbl 1163.65310
[12] Stüben, K.; Clees, T.; Klie, H.; Lu, B.; Wheeler, M. F., Algebraic Multigrid Methods (AMG) for the efficient solution of fully implicit formulations in reservoir simulation, (Proc. of SPE Reservoir Simulation Symposium, 2007), SPE-105832-MS
[13] Cao, H.; Tchelepi, H. A.; Wallis, J.; Yardumian, H., Parallel scalable unstructured CPR-type linear solver for reservoir simulation, (SPE Annual Technical Conference and Exhibition, vol. All Days, 2005), SPE-96809-MS
[14] Gries, S.; Stüben, K.; Brown, G.; Chen, D.; Collins, D., Preconditioning for efficiently applying algebraic multigrid in fully implicit reservoir simulations, SPE J., 19, 04, 726-736, 2014
[15] G. Li, J. Wallis, G. Shaw, A Parallel Linear Solver Algorithm for Solving Difficult Large Scale Thermal Models, in: Proc. of SPE Reservoir Simulation Symposium, 2015, pp. SPE-173207-MS.
[16] Roy, T.; Jönsthövel, T. B.; Lemon, C.; Wathen, A. J., A block preconditioner for non-isothermal flow in porous media, J. Comput. Phys., 395, 636-652, 2019 · Zbl 1452.65053
[17] Cremon, M.; Castelletto, N.; White, J., Multi-stage preconditioners for thermal-compositional-reactive flow in porous media, J. Comput. Phys., 418, Article 109607 pp., 2020 · Zbl 07506171
[18] Roy, T.; Jönsthövel, T. B.; Lemon, C.; Wathen, A. J., A Constrained Pressure-Temperature Residual (CPTR) method for non-isothermal multiphase flow in porous media, SIAM J. Sci. Comput., 42, 4, B1014-B1040, 2020 · Zbl 1452.76101
[19] Rice, J. R., The algorithm selection problem, (Advances in Computers, vol. 15, 1976, Elsevier), 65-118
[20] Smith-Miles, K. A., Cross-disciplinary perspectives on meta-learning for algorithm selection, ACM Comput. Surv., 41, 1-25, 2009
[21] Bischl, B.; Kerschke, P.; Kotthoff, L.; Lindauer, M.; Malitsky, Y.; Fréchette, A.; Hoos, H.; Hutter, F.; Leyton-Brown, K.; Tierney, K.; Vanschoren, J., ASlib: A benchmark library for algorithm selection, Artificial Intelligence, 237, 41-58, 2016 · Zbl 1357.68202
[22] Jessup, E.; Motter, P.; Norris, B.; Sood, K., Performance-based numerical solver selection in the lighthouse framework, SIAM J. Sci. Comput., 38, 5, S750-S771, 2016 · Zbl 1352.65107
[23] Weerawarana, S.; Houstis, E. N.; Rice, J. R.; Joshi, A.; Houstis, C. E., PYTHIA: A knowledge-based system to select scientific algorithms, ACM Trans. Math. Software, 22, 4, 447-468, 1996 · Zbl 0884.65123
[24] Dongarra, J.; Bosilca, G.; Chen, Z.; Eijkhout, V.; Fagg, G. E.; Fuentes, E.; Langou, J.; Luszczek, P.; Pjesivac-Grbovic, J.; Seymour, K.; You, H.; Vadhiyar, S. S., Self-Adapting Numerical Software (SANS) effort, IBM J. Res. Dev., 50, 2.3, 223-238, 2006
[25] Bhowmick, S.; Eijkhout, V.; Freund, Y.; Fuentes, E.; Keyes, D., Application of alternating decision trees in selecting sparse linear solvers, (Naono, K.; Teranishi, K.; Cavazos, J.; Suda, R., Software Automatic Tuning, 2011, Springer New York: Springer New York New York, NY), 153-173
[26] Eller, P. R.; Cheng, J.-R. C.; Maier, R. S., Dynamic linear solver selection for transient simulations using machine learning on distributed systems, (2012 IEEE 26th International Parallel and Distributed Processing Symposium Workshops & PhD Forum, 2012), 1915-1924
[27] Z. Tang, H. Zhang, J. Chen, Graph Neural Networks for Selection of Preconditioners and Krylov Solvers, in: NeurIPS 2022 Workshop: New Frontiers in Graph Learning, 2022, pp. 1-11.
[28] Liu, Y.; Sid-Lakhdar, W. M.; Marques, O.; Zhu, X.; Meng, C.; Demmel, J. W.; Li, X. S., GPTune: Multitask learning for autotuning exascale applications, (Proceedings of the 26th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming. Proceedings of the 26th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, PPoPP ’21, 2021, Association for Computing Machinery), 234-246
[29] Roy, R. B.; Patel, T.; Gadepally, V.; Tiwari, D., Bliss: auto-tuning complex applications using a pool of diverse lightweight learning models, (Proceedings of the 42nd ACM SIGPLAN International Conference on Programming Language Design and Implementation, 2021, ACM: ACM Virtual Canada), 1280-1295
[30] Rasmussen, C. E.; Williams, C. K., Gaussian Processes for Machine Learning, 2006, Springer · Zbl 1177.68165
[31] Mishev, I.; Beckner, B.; Fedorova, N.; Terekhov, S., Linear solver performance optimization in reservoir simulation studies, (Proc. of SPE Reservoir Simulation Symposium, 2009), SPE-119266-MS
[32] Bhowmick, S.; Kaushik, D.; McInnes, L.; Norris, B.; Raghavan, P., Parallel adaptive solvers in compressible PETSc-FUN3D simulations*, (Deane, A.; Ecer, A.; McDonough, J.; Satofuka, N.; Brenner, G.; Emerson, D. R.; Periaux, J.; Tromeur-Dervout, D., Parallel Computational Fluid Dynamics 2005, 2006, Elsevier: Elsevier Amsterdam), 277-284
[33] Clees, T.; Ganzer, L., An efficient algebraic multigrid solver strategy for adaptive implicit methods in OilReservoir simulation, SPE J., 15, 670-681, 2010
[34] Silva, V. L.; Salinas, P.; Jackson, M. D.; Pain, C. C., Machine learning acceleration for nonlinear solvers applied to multiphase porous media flow, Comput. Methods Appl. Mech. Engrg., 384, 2021 · Zbl 1506.76176
[35] Jiranek, P.; Strakos, Z.; Vohralík, M., A posteriori error estimates including algebraic error: computable upper bounds and stopping criteria for iterative solvers, SIAM J. Sci. Comput., 32, 3, 1567-1590, 2010 · Zbl 1215.65168
[36] Ahmed, E.; Nordbotten, J. M.; Radu, F. A., Adaptive asynchronous time-stepping, stopping criteria, and a posteriori error estimates for fixed-stress iterative schemes for coupled poromechanics problems, J. Comput. Appl. Math., 364, Article 112312 pp., 2020 · Zbl 1524.76439
[37] Ramesh Kumar, K.; Tene, M., Algebraic multiscale grid coarsening using unsupervised machine learning for subsurface flow simulation, J. Comput. Phys., 496, Article 112570 pp., 2024 · Zbl 07807981
[38] Huang, R.; Li, R.; Xi, Y., Learning optimal multigrid smoothers via neural networks, SIAM J. Sci. Comput., 45, 3, S199-S225, 2023 · Zbl 07704371
[39] Antonietti, P. F.; Caldana, M.; Dede’, L., Accelerating algebraic multigrid methods via artificial neural networks, Vietnam J. Math., 51, 1, 1-36, 2023 · Zbl 1514.65188
[40] Antonietti, P.; Farenga, N.; Manuzzi, E.; Martinelli, G.; Saverio, L., Agglomeration of polygonal grids using graph neural networks with applications to multigrid solvers, Comput. Math. Appl., 154, 45-57, 2024 · Zbl 1538.65487
[41] Nguyen, D.; Gupta, S.; Rana, S.; Shilton, A.; Venkatesh, S., Bayesian optimization for categorical and category-specific continuous inputs, Proc. Int. AAAI Conf., 34, 04, 5256-5263, 2020
[42] Shahriari, B.; Swersky, K.; Wang, Z.; Adams, R. P.; de Freitas, N., Taking the human out of the loop: A review of Bayesian optimization, Proc. IEEE, 104, 1, 148-175, 2016
[43] Friedman, J. H., Greedy function approximation: A gradient boosting machine, Ann. Statist., 29, 5, 1189-1232, 2001 · Zbl 1043.62034
[44] Coussy, O., Poromechanics, 2004, John Wiley & Sons
[45] Aziz, K.; Settari, A., Petroleum Reservoir Simulation, 1979, Springer: Springer Netherlands
[46] Nordbotten, J. M., Stable cell-centered finite volume discretization for Biot equations, SIAM J. Numer. Anal., 54, 2, 942-968, 2016 · Zbl 1382.76187
[47] Both, J. W.; Köcher, U., Numerical investigation on the fixed-stress splitting scheme for Biot’s equations: Optimality of the tuning parameter, (Radu, F. A.; Kumar, K.; Berre, I.; Nordbotten, J. M.; Pop, I. S., Numerical Mathematics and Advanced Applications ENUMATH 2017, 2019, Springer International Publishing: Springer International Publishing Cham), 789-797 · Zbl 1425.76132
[48] Peaceman, D., Interpretation of well-block pressures in numerical reservoir simulation(includes associated paper 6988 ), SPE J., 18, 03, 183-194, 1978
[49] Chen, Z.; Zhang, Y., Well flow models for various numerical methods, Int. J. Numer. Anal. Mode., 6, 2009 · Zbl 1158.76393
[50] Zabegaev, Y.; Keilegavlen, E.; Iversen, E.; Berre, I., Runscripts for the Manuscript ‘Automated Solver Selection for Simulation of Multiphysics Processes in Porous Media’, 2024, Zenodo
[51] Keilegavlen, E.; Berge, R.; Fumagalli, A.; Starnoni, M.; Stefansson, I.; Varela, J.; Berre, I., PorePy: An open-source software for simulation of multiphysics processes in fractured porous media, Comput. Geosci., 25, 243-265, 2021 · Zbl 1453.86001
[52] Pedregosa, F.; Varoquaux, G.; Gramfort, A.; Michel, V.; Thirion, B.; Grisel, O.; Blondel, M.; Prettenhofer, P.; Weiss, R.; Dubourg, V.; Vanderplas, J.; Passos, A.; Cournapeau, D.; Brucher, M.; Perrot, M.; Duchesnay, E., Scikit-learn: Machine learning in Python, J. Mach. Learn. Res., 12, 2825-2830, 2011 · Zbl 1280.68189
[53] Virtanen, P.; Gommers, R.; Oliphant, T. E.; Haberland, M.; Reddy, T.; Cournapeau, D.; Burovski, E.; Peterson, P.; Weckesser, W.; Bright, J.; van der Walt, S. J.; Brett, M.; Wilson, J.; Millman, K. J.; Mayorov, N.; Nelson, A. R.J.; Jones, E.; Kern, R.; Larson, E.; Carey, C. J.; Polat, İ.; Feng, Y.; Moore, E. W.; VanderPlas, J.; Laxalde, D.; Perktold, J.; Cimrman, R.; Henriksen, I.; Quintero, E. A.; Harris, C. R.; Archibald, A. M.; Ribeiro, A. H.; Pedregosa, F.; van Mulbregt, P.; SciPy 1.0 Contributors, SciPy 1.0: Fundamental algorithms for scientific computing in Python, Nat. Methods., 17, 261-272, 2020
[54] Bell, N.; Olson, L.; Schroder, J.; Southworth, B., PyAMG: Algebraic multigrid solvers in Python, J. Open Source Softw., 8, 87, 5495, 2023
[55] Balay, S.; Abhyankar, S.; Adams, M. F.; Benson, S.; Brown, J.; Brune, P.; Buschelman, K.; Constantinescu, E.; Dalcin, L.; Dener, A.; Eijkhout, V.; Faibussowitsch, J.; Gropp, W. D.; Hapla, V.; Isaac, T.; Jolivet, P.; Karpeev, D.; Kaushik, D.; Knepley, M. G.; Kong, F.; Kruger, S.; May, D. A.; McInnes, L. C.; Mills, R. T.; Mitchell, L.; Munson, T.; Roman, J. E.; Rupp, K.; Sanan, P.; Sarich, J.; Smith, B. F.; Zampini, S.; Zhang, H.; Zhang, H.; Zhang, J., PETSc/TAO Users ManualTech. Rep. ANL-21/39 - Revision 3.19, 2023, Argonne National Laboratory
[56] Dalcin, L. D.; Paz, R. R.; Kler, P. A.; Cosimo, A., Parallel distributed computing using python, Adv. Water Resour., 34, 9, 1124-1139, 2011, New Computational Methods and Software Tools
[57] Henson, V. E.; Yang, U. M., BoomerAMG: A parallel algebraic multigrid solver and preconditioner, Appl. Numer. Math., 41, 1, 155-177, 2002, Developments and Trends in Iterative Methods for Large Systems of Equations - in memorium Rudiger Weiss · Zbl 0995.65128
[58] Vakili, S.; Moss, H.; Artemev, A.; Dutordoir, V.; Picheny, V., Scalable thompson sampling using sparse Gaussian process models, (Ranzato, M.; Beygelzimer, A.; Dauphin, Y.; Liang, P.; Vaughan, J. W., Advances in Neural Information Processing Systems, vol. 34, 2021, Curran Associates, Inc.), 5631-5643
[59] Mandel, J., Consolidation des sols (Étude Mathématique), Géotechnique, 3, 7, 287-299, 1953
[60] Christie, M. A.; Blunt, M. J., Tenth SPE comparative solution project: A comparison of upscaling techniques, SPE Reserv. Eval. Eng., 4, 04, 308-317, 2001
[61] Bennison, T., Prediction of heavy oil viscosity, (IBC Heavy Oil Field Development Conference, vol. 2, 1998, Citeseer), 4
This reference list is based on information provided by the publisher or from digital mathematics libraries. Its items are heuristically matched to zbMATH identifiers and may contain data conversion errors. In some cases that data have been complemented/enhanced by data from zbMATH Open. This attempts to reflect the references listed in the original paper as accurately as possible without claiming completeness or a perfect matching.