:mod:`eggshell.nc.ocg_utils` ============================ .. py:module:: eggshell.nc.ocg_utils Module Contents --------------- .. data:: LOGGER .. data:: temp_groups .. function:: call(resource=[], variable=None, dimension_map=None, agg_selection=True, calc=None, calc_grouping=None, conform_units_to=None, crs=None, memory_limit=None, prefix=None, regrid_destination=None, regrid_options='bil', level_range=None, geom=None, output_format_options=None, search_radius_mult=2.0, select_nearest=False, select_ugid=None, spatial_wrapping=None, t_calendar=None, time_region=None, time_range=None, dir_output=None, output_format='nc') Call OCGIS operation. :param resource: Input netCDF file. :param variable: variable in the input file to be picked :param dimension_map: dimension map in case of unconventional storage of data :param agg_selection: For aggregation of in case of mulitple polygons geoms :param calc: ocgis calc syntax for calculation partion :param calc_grouping: time aggregate grouping :param cdover: OUTDATED use py-cdo ('python', by default) or cdo from the system ('system') :param conform_units_to: :param crs: coordinate reference system :param memory_limit: limit the amount of data to be loaded into the memory at once if None (default) free memory is detected by birdhouse :param level_range: subset of given levels :param prefix: string for the file base name :param regrid_destination: file path with netCDF file with grid for output file :param geom: name of shapefile stored in birdhouse shape cabinet :param output_format_options: output options for netCDF e.g compression level() :param regrid_destination: file containing the targed grid (griddes.txt or netCDF file) :param regrid_options: methods for regridding: 'bil' = Bilinear interpolation 'bic' = Bicubic interpolation 'dis' = Distance-weighted average remapping 'nn' = nearest neighbour 'con' = First-order conservative remapping 'laf' = largest area fraction reamapping :param search_radius_mult: search radius for point geometries. All included gridboxes will be returned :param select_nearest: nearest neighbour selection for point geometries :param select_ugid: ugid for appropriate polygons :param spatial_wrapping: how to handle coordinates in case of subsets, options: None (default), 'wrap', 'unwrap' :param time_region: select single month :param time_range: sequence of two datetime.datetime objects to mark start and end point :param dir_output (default= curdir): :param output_format: :return: output file path .. function:: calc_grouping(grouping) translate time grouping abbreviation (e.g 'JJA') into the appropriate ocgis calc_grouping syntax :param grouping: time group abbreviation allowed values: "yr", "mon", "sem", "ONDJFM", "AMJJAS", "DJF", "MAM", "JJA", "SON" :returns list: calc_grouping conformant to ocgis syntax .. function:: get_variable(resource) detects processable variable name in netCDF file based on ocgis (compare guess_main_variables) :param resource: filepath sting or sorted list for netcdf file(s) :returns str: variable name .. function:: has_variable(resource, variable)