How to use mixed precision in ocean models: exploring a potential reduction of numerical precision in NEMO 4.0 and ROMS 3.6

Main Authors: Oriol Tintó Prims, Mario C. Acosta, Andrew M. Moore, Miguel Castrillo, Kim Serradell, Ana Cortés, Francisco J. Doblas-Reyes
Format: Article eJournal
Bahasa: eng
Terbitan: , 2019
Subjects:
hpc
Online Access: https://zenodo.org/record/4114704
ctrlnum 4114704
fullrecord <?xml version="1.0"?> <dc schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd"><creator>Oriol Tint&#xF3; Prims</creator><creator>Mario C. Acosta</creator><creator>Andrew M. Moore</creator><creator>Miguel Castrillo</creator><creator>Kim Serradell</creator><creator>Ana Cort&#xE9;s</creator><creator>Francisco J. Doblas-Reyes</creator><date>2019-07-24</date><description>Mixed-precision approaches can provide substantial speed-ups for both computing- and memory-bound codes with little effort. Most scientific codes have overengineered the numerical precision, leading to a situation in which models are using more resources than required without knowing where they are required and where they are not. Consequently, it is possible to improve computational performance by establishing a more appropriate choice of precision. The only input that is needed is a method to determine which real variables can be represented with fewer bits without affecting the accuracy of the results. This paper presents a novel method that enables modern and legacy codes to benefit from a reduction of the precision of certain variables without sacrificing accuracy. It consists of a simple idea: we reduce the precision of a group of variables and measure how it affects the outputs. Then we can evaluate the level of precision that they truly need. Modifying and recompiling the code for each case that has to be evaluated would require a prohibitive amount of effort. Instead, the method presented in this paper relies on the use of a tool called a reduced-precision emulator (RPE) that can significantly streamline the process. Using the RPE and a list of parameters containing the precisions that will be used for each real variable in the code, it is possible within a single binary to emulate the effect on the outputs of a specific choice of precision. When we are able to emulate the effects of reduced precision, we can proceed with the design of the tests that will give us knowledge of the sensitivity of the model variables regarding their numerical precision. The number of possible combinations is prohibitively large and therefore impossible to explore. The alternative of performing a screening of the variables individually can provide certain insight about the required precision of variables, but, on the other hand, other complex interactions that involve several variables may remain hidden. Instead, we use a divide-and-conquer algorithm that identifies the parts that require high precision and establishes a set of variables that can handle reduced precision. This method has been tested using two state-of-the-art ocean models, the Nucleus for European Modelling of the Ocean (NEMO) and the Regional Ocean Modeling System (ROMS), with very promising results. Obtaining this information is crucial to build an actual mixed-precision version of the code in the next phase that will bring the promised performance benefits.</description><identifier>https://zenodo.org/record/4114704</identifier><identifier>10.5194/gmd-12-3135-2019</identifier><identifier>oai:zenodo.org:4114704</identifier><language>eng</language><relation>info:eu-repo/grantAgreement/EC/H2020/823988/</relation><relation>url:https://zenodo.org/communities/esiwace</relation><rights>info:eu-repo/semantics/openAccess</rights><rights>https://creativecommons.org/licenses/by/4.0/legalcode</rights><subject>hpc</subject><subject>mixed precision</subject><subject>earth system modelling</subject><title>How to use mixed precision in ocean models: exploring a potential reduction of numerical precision in NEMO 4.0 and ROMS 3.6</title><type>Journal:Article</type><type>Journal:Article</type><recordID>4114704</recordID></dc>
language eng
format Journal:Article
Journal
Journal:eJournal
author Oriol Tintó Prims
Mario C. Acosta
Andrew M. Moore
Miguel Castrillo
Kim Serradell
Ana Cortés
Francisco J. Doblas-Reyes
title How to use mixed precision in ocean models: exploring a potential reduction of numerical precision in NEMO 4.0 and ROMS 3.6
publishDate 2019
isbn 9781231352014
topic hpc
mixed precision
earth system modelling
url https://zenodo.org/record/4114704
contents Mixed-precision approaches can provide substantial speed-ups for both computing- and memory-bound codes with little effort. Most scientific codes have overengineered the numerical precision, leading to a situation in which models are using more resources than required without knowing where they are required and where they are not. Consequently, it is possible to improve computational performance by establishing a more appropriate choice of precision. The only input that is needed is a method to determine which real variables can be represented with fewer bits without affecting the accuracy of the results. This paper presents a novel method that enables modern and legacy codes to benefit from a reduction of the precision of certain variables without sacrificing accuracy. It consists of a simple idea: we reduce the precision of a group of variables and measure how it affects the outputs. Then we can evaluate the level of precision that they truly need. Modifying and recompiling the code for each case that has to be evaluated would require a prohibitive amount of effort. Instead, the method presented in this paper relies on the use of a tool called a reduced-precision emulator (RPE) that can significantly streamline the process. Using the RPE and a list of parameters containing the precisions that will be used for each real variable in the code, it is possible within a single binary to emulate the effect on the outputs of a specific choice of precision. When we are able to emulate the effects of reduced precision, we can proceed with the design of the tests that will give us knowledge of the sensitivity of the model variables regarding their numerical precision. The number of possible combinations is prohibitively large and therefore impossible to explore. The alternative of performing a screening of the variables individually can provide certain insight about the required precision of variables, but, on the other hand, other complex interactions that involve several variables may remain hidden. Instead, we use a divide-and-conquer algorithm that identifies the parts that require high precision and establishes a set of variables that can handle reduced precision. This method has been tested using two state-of-the-art ocean models, the Nucleus for European Modelling of the Ocean (NEMO) and the Regional Ocean Modeling System (ROMS), with very promising results. Obtaining this information is crucial to build an actual mixed-precision version of the code in the next phase that will bring the promised performance benefits.
id IOS17403.4114704
institution Universitas PGRI Palembang
institution_id 189
institution_type library:university
library
library Perpustakaan Universitas PGRI Palembang
library_id 587
collection Marga Life in South Sumatra in the Past: Puyang Concept Sacrificed and Demythosized
repository_id 17403
city KOTA PALEMBANG
province SUMATERA SELATAN
repoId IOS17403
first_indexed 2022-07-26T01:35:18Z
last_indexed 2022-07-26T01:35:18Z
recordtype dc
_version_ 1739406782620499968
score 17.538404