Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" ?>
<cubes xmlns="urn:x-iris:cubeml-0.2">
<cube core-dtype="float64" dtype="int32" standard_name="land_binary_mask" units="1" var_name="land_binary_mask">
<cube core-dtype="int32" dtype="int32" standard_name="land_binary_mask" units="1" var_name="land_binary_mask">
<attributes>
<attribute name="Conventions" value="CF-1.5"/>
<attribute name="source" value="Data from Met Office Unified Model"/>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" ?>
<cubes xmlns="urn:x-iris:cubeml-0.2">
<cube core-dtype="float64" dtype="int32" standard_name="land_binary_mask" units="1">
<cube core-dtype="int32" dtype="int32" standard_name="land_binary_mask" units="1">
<attributes>
<attribute name="source" value="Data from Met Office Unified Model"/>
</attributes>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dimensions:
longitude = 96 ;
variables:
float air_temperature(latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dimensions:
longitude = 96 ;
variables:
float air_temperature(latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dimensions:
longitude = 96 ;
variables:
float air_temperature(latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 96 ;
variables:
float geopotential_height(pressure, latitude, longitude) ;
geopotential_height:_FillValue = 9.96921e+36f ;
geopotential_height:standard_name = "geopotential_height" ;
geopotential_height:units = "m" ;
geopotential_height:um_stash_source = "m01s16i202" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dimensions:
longitude = 128 ;
variables:
float sea_surface_height_above_geoid(latitude, longitude) ;
sea_surface_height_above_geoid:_FillValue = -1.e+30f ;
sea_surface_height_above_geoid:_FillValue = 9.96921e+36f ;
sea_surface_height_above_geoid:standard_name = "sea_surface_height_above_geoid" ;
sea_surface_height_above_geoid:units = "m" ;
sea_surface_height_above_geoid:grid_mapping = "latitude_longitude" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dimensions:
latitude = 73 ;
variables:
float unknown(depth, latitude) ;
unknown:_FillValue = -1.e+30f ;
unknown:_FillValue = 9.96921e+36f ;
unknown:um_stash_source = "m??s44i101" ;
unknown:ukmo__process_flags = "Mean_over_an_ensemble_of_parallel_runs Time_mean_field" ;
unknown:grid_mapping = "latitude_longitude" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ dimensions:
time = 16 ;
variables:
float unknown(depth, time) ;
unknown:_FillValue = 9.96921e+36f ;
unknown:um_stash_source = "m??s44i101" ;
unknown:cell_methods = "time: mean (interval: 24 hour)" ;
float depth(depth) ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 192 ;
variables:
float change_over_time_in_upward_air_velocity_due_to_advection(model_level_number, latitude, longitude) ;
change_over_time_in_upward_air_velocity_due_to_advection:_FillValue = 9.96921e+36f ;
change_over_time_in_upward_air_velocity_due_to_advection:long_name = "change_over_time_in_upward_air_velocity_due_to_advection" ;
change_over_time_in_upward_air_velocity_due_to_advection:units = "m s-1" ;
change_over_time_in_upward_air_velocity_due_to_advection:um_stash_source = "m01s12i187" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dimensions:
site_number = 3 ;
variables:
float air_temperature(time, site_number) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "Celsius" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
pressure = 15 ;
variables:
float geopotential_height(time, pressure, latitude) ;
geopotential_height:_FillValue = 9.96921e+36f ;
geopotential_height:standard_name = "geopotential_height" ;
geopotential_height:units = "m" ;
geopotential_height:um_stash_source = "m01s16i202" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ dimensions:
pressure = 15 ;
variables:
float geopotential_height(time, pressure, latitude, longitude) ;
geopotential_height:_FillValue = 9.96921e+36f ;
geopotential_height:standard_name = "geopotential_height" ;
geopotential_height:units = "m" ;
geopotential_height:um_stash_source = "m01s16i202" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 96 ;
variables:
float air_temperature(time, latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 10 ;
variables:
float air_temperature(time, latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:cell_methods = "time: mean (interval: 1 hour)" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ dimensions:
time = 4 ;
variables:
float geopotential_height(pressure, time) ;
geopotential_height:_FillValue = 9.96921e+36f ;
geopotential_height:standard_name = "geopotential_height" ;
geopotential_height:units = "m" ;
geopotential_height:um_stash_source = "m01s16i202" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ dimensions:
site_number = 1 ;
variables:
float air_temperature(time, site_number) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 96 ;
variables:
float air_temperature(time, latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 96 ;
variables:
float air_temperature(time, latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s03i236" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dimensions:
longitude = 96 ;
variables:
float precipitation_flux(time, latitude, longitude) ;
precipitation_flux:_FillValue = 9.96921e+36f ;
precipitation_flux:standard_name = "precipitation_flux" ;
precipitation_flux:units = "kg m-2 s-1" ;
precipitation_flux:um_stash_source = "m01s05i216" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dimensions:
latitude = 73 ;
variables:
float geopotential_height(pressure, latitude) ;
geopotential_height:_FillValue = 9.96921e+36f ;
geopotential_height:standard_name = "geopotential_height" ;
geopotential_height:units = "m" ;
geopotential_height:um_stash_source = "m01s16i202" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dimensions:
longitude = 96 ;
variables:
int land_binary_mask(latitude, longitude) ;
land_binary_mask:_FillValue = -2147483647 ;
land_binary_mask:standard_name = "land_binary_mask" ;
land_binary_mask:units = "1" ;
land_binary_mask:cell_methods = "time: mean" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ dimensions:
pressure = 9 ;
variables:
float air_temperature(time, pressure, latitude, longitude) ;
air_temperature:_FillValue = 9.96921e+36f ;
air_temperature:standard_name = "air_temperature" ;
air_temperature:units = "K" ;
air_temperature:um_stash_source = "m01s16i203" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dimensions:
latitude = 144 ;
variables:
float sea_water_potential_temperature(depth, latitude) ;
sea_water_potential_temperature:_FillValue = -1.e+30f ;
sea_water_potential_temperature:_FillValue = 9.96921e+36f ;
sea_water_potential_temperature:standard_name = "sea_water_potential_temperature" ;
sea_water_potential_temperature:units = "degC" ;
sea_water_potential_temperature:um_stash_source = "m02s00i101" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dimensions:
longitude = 288 ;
variables:
float unknown(latitude, longitude) ;
unknown:_FillValue = -1.e+30f ;
unknown:_FillValue = 9.96921e+36f ;
unknown:um_stash_source = "m02s00i???" ;
unknown:cell_methods = "time: mean (interval: 2 hour)" ;
unknown:grid_mapping = "latitude_longitude" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ dimensions:
time = 4 ;
variables:
float unknown(pseudo_level, time, depth, grid_latitude) ;
unknown:_FillValue = -1.e+30f ;
unknown:_FillValue = 9.96921e+36f ;
unknown:um_stash_source = "m02s00i???" ;
unknown:cell_methods = "time: mean" ;
unknown:grid_mapping = "rotated_latitude_longitude" ;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ dimensions:
time = 4 ;
variables:
float northward_ocean_heat_transport(pseudo_level, time, latitude, longitude) ;
northward_ocean_heat_transport:_FillValue = -1.e+30f ;
northward_ocean_heat_transport:_FillValue = 9.96921e+36f ;
northward_ocean_heat_transport:standard_name = "northward_ocean_heat_transport" ;
northward_ocean_heat_transport:units = "PW" ;
northward_ocean_heat_transport:um_stash_source = "m02s30i211" ;
Expand Down
10 changes: 8 additions & 2 deletions lib/iris/tests/test_pp_cf.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
import types
import warnings

import netCDF4

import iris
import iris.tests.pp as pp
import iris.util
Expand Down Expand Up @@ -80,7 +82,6 @@ def callback_aaxzc_n10r13xy_b_pp(cube, field, filename):
cube.add_aux_coord(height_coord)


@tests.skip_dask_mask
@tests.skip_data
class TestAll(tests.IrisTest, pp.PPTest):
_ref_dir = ('usecases', 'pp_to_cf_conversion')
Expand All @@ -105,8 +106,13 @@ def _test_file(self, name):
nc_filenames = []

for index, cube in enumerate(cubes):
# Explicitly set a fill-value as a workaround for
# https://github.com/Unidata/netcdf4-python/issues/725
fill_value = netCDF4.default_fillvals[cube.dtype.str[1:]];

file_nc = tempfile.NamedTemporaryFile(suffix='.nc', delete=False).name
iris.save(cube, file_nc, netcdf_format='NETCDF3_CLASSIC')
iris.save(cube, file_nc, netcdf_format='NETCDF3_CLASSIC',
fill_value=fill_value)

# Check the netCDF file against CDL expected output.
self.assertCDL(file_nc, self._ref_dir + ('to_netcdf', '%s_%d.cdl' % (fname_name, index)))
Expand Down