PISM, A Parallel Ice Sheet Model 2.3.0-79cae578d committed by Constantine Khrulev on 2026-03-22
Loading...
Searching...
No Matches

◆ check_consistency_epsg()

void pism::check_consistency_epsg ( const VariableMetadata cf_mapping,
const std::string &  proj_string 
)

Check consistency of the "mapping" variable with the EPSG code in the proj string.

If the consistency check fails, throws RuntimeError explaining the failure. Fails if info.proj does not use an EPSG code.

Definition at line 145 of file projection.cc.

References pism::VariableMetadata::all_doubles(), pism::VariableMetadata::all_strings(), epsg_to_cf(), pism::RuntimeError::formatted(), pism::VariableMetadata::get_number(), pism::VariableMetadata::has_attribute(), PISM_ERROR_LOCATION, and pism::VariableMetadata::unit_system().

Referenced by mapping_info_from_file().