diff --git a/pysurfex/cli.py b/pysurfex/cli.py index c3fffae..7740e01 100644 --- a/pysurfex/cli.py +++ b/pysurfex/cli.py @@ -167,6 +167,13 @@ def run_first_guess_for_oi(**kwargs): fileformat = kwargs["sd_format"] if "sd_converter" in kwargs and kwargs["sd_converter"] is not None: converter = kwargs["sd_converter"] + elif var == "sea_ice_thickness": + if "icetk_file" in kwargs and kwargs["icetk_file"] is not None: + inputfile = kwargs["icetk_file"] + if "icetk_format" in kwargs and kwargs["icetk_format"] is not None: + fileformat = kwargs["icetk_format"] + if "icetk_converter" in kwargs and kwargs["icetk_converter"] is not None: + converter = kwargs["icetk_converter"] elif var == "cloud_base": if "cb_file" in kwargs and kwargs["cb_file"] is not None: inputfile = kwargs["cb_file"] diff --git a/pysurfex/cmd_parsing.py b/pysurfex/cmd_parsing.py index dc1d09e..0dcd135 100644 --- a/pysurfex/cmd_parsing.py +++ b/pysurfex/cmd_parsing.py @@ -618,6 +618,26 @@ def parse_args_first_guess_for_oi(argv): choices=["none", "sweclim", "swe2sd", "sdp"], ) + parser.add_argument( + "-icetk_file", type=str, default=None, help="Ice thickness file", nargs="?" + ) + parser.add_argument( + "-icetk_format", + type=str, + default=None, + help="Ice thickness file format", + nargs="?", + choices=["fa"], + ) + parser.add_argument( + "--icetk_converter", + type=str, + default="none", + help="", + nargs="?", + choices=["none"], + ) + parser.add_argument( "-cb_file", type=str, default=None, help="Cloud base file", nargs="?" ) @@ -721,6 +741,7 @@ def parse_args_first_guess_for_oi(argv): "air_temperature_2m", "relative_humidity_2m", "surface_snow_thickness", + "sea_ice_thickness", "cloud_base", "surface_soil_moisture", ], diff --git a/pysurfex/netcdf.py b/pysurfex/netcdf.py index 10c8da1..c5fb157 100644 --- a/pysurfex/netcdf.py +++ b/pysurfex/netcdf.py @@ -643,6 +643,7 @@ def create_netcdf_first_guess_template( "relative_humidity_2m": "relative_humidity", "altitude": "altitude", "surface_snow_thickness": "surface_snow_thickness", + "sea_ice_thickness": "sea_ice_thickness", "surface_soil_moisture": "surface_soil_moisture", "cloud_base": "cloud_base", "land_area_fraction": "land_area_fraction", @@ -652,6 +653,7 @@ def create_netcdf_first_guess_template( "relative_humidity_2m": "Screen level relative humidity (RH2M)", "altitude": "Altitude", "surface_snow_thickness": "Surface snow thickness", + "sea_ice_thickness": "Sea ice thickness", "surface_soil_moisture": "Surface soil moisture", "cloud_base": "Cloud base", "land_area_fraction": "Land Area Fraction", @@ -661,6 +663,7 @@ def create_netcdf_first_guess_template( "relative_humidity_2m": "1", "altitude": "m", "surface_snow_thickness": "m", + "sea_ice_thickness": "m", "surface_soil_moisture": "m3/m3", "cloud_base": "m", "land_area_fraction": "1", @@ -670,6 +673,7 @@ def create_netcdf_first_guess_template( "relative_humidity_2m": "9.96921e+36", "altitude": "9.96921e+36", "surface_snow_thickness": "9.96921e+36", + "sea_ice_thickness": "9.96921e+36", "surface_soil_moisture": "9.96921e+36", "cloud_base": "9.96921e+36", "land_area_fraction": "9.96921e+36",