wolfhece.mar.commontools
Created on Mon Dec 5 09:03:34 2022
@author: jbrajkovic
Module Contents
- wolfhece.mar.commontools.text_into_matrix(model_name, scenario, mx, my, sy, ey)[source]
This function reads precipitation text files to put all of it in a 3D matrix of yearly precipitation
- wolfhece.mar.commontools.quick_map_plot(lons, lats, mat, bounds, cmap, MSK=np.zeros(0), nticks=4)[source]
- wolfhece.mar.commontools.mask_belgium(lon, lat, path_in, path_out, center_or_all=2)[source]
- This routine takes as arguments:
-The longitudes and latitudes of the netcdf (gridded) -a .tif file of the mask we want to create (tif must be in epsg:31370 lambbert 72)
and creates a mask at the resolution of the input netcdf which is saved as netcdf in path_out
L’option center_or_all precise si l’on souhaite qu’un des 4 coins des pixels chosisis soient à l’intérieur de la zone ou si on regarde uniquement le centre. Si center_or_all vaut 1, on ragarde uniquement le centre et donc le masque sera plus petit
conseil : raster d’une résolution 100 mètres en input’
- wolfhece.mar.commontools.mask_belgiumV2(lon, lat, path_in, path_out, center_or_all=2, discheck=300000, buffer=2)[source]
- This routine takes as arguments:
-The longitudes and latitudes of the netcdf (gridded) -a .tif file of the mask we want to create (tif must be in epsg:31370 lambbert 72)
and creates a mask at the resolution of the input netcdf which is saved as netcdf in path_out
L’option center_or_all precise si l’on souhaite qu’un des 4 coins des pixels chosisis soient à l’intérieur de la zone ou si on regarde uniquement le centre. Si center_or_all vaut 1, on ragarde uniquement le centre et donc le masque sera plus petit
conseil : raster d’une résolution 100 mètres en input’
- wolfhece.mar.commontools.grid_mean(folder, year, var, season, sum_or_mean=0, nts=24, lev=0, nf=0, fn1='__')[source]
- wolfhece.mar.commontools.GEVCI(retp, loc, sc, sh, varloc, varsc, varsh, covlocsc, covlocsh, covscsh)[source]
- wolfhece.mar.commontools.extreme_matrix(fn, ret_per=20, value=50, mx=80, my=50, abs_or_retour=1, ydays=365, start_year=2011, end_year=2040, nts=24, gpd_gev_gum=0)[source]