windkit.read_wwc#
- windkit.read_wwc(filename, *, file_format='infer', **kwargs)[source]#
Read a weibull wind climate dataset from a file.
- Parameters:
filename (str or pathlib.Path) – Path to the file to read the dataset from.
file_format (str) – File format of the file. If “infer”, the file format is inferred from the file extension. Supported file formats are “rsf”, “wrg”, “grd”, “nc”, and “yaml” (windIO). Defaults to “infer”.
**kwargs – Additional keyword arguments passed to the read function. For windIO format (yaml),
crsis required if not present in the file. Also,levelcan be specified to indicate the windIO hierarchy level of the input file: ‘plant’, ‘site’, ‘energy_resource’, or ‘wind_resource’. Defaults to ‘plant’.
- Returns:
Weibull wind climate dataset.
- Return type:
Examples
>>> import windkit as wk >>> # Read from .rsf file >>> wwc = wk.read_wwc("resource.rsf", crs="EPSG:32632") >>> # Read from .wrg file >>> wwc = wk.read_wwc("resource.wrg", crs="EPSG:32632") >>> # Read from windIO YAML format >>> wwc = wk.read_wwc("plant.yaml", crs="EPSG:32632") >>> # Read from a standalone wind_resource file >>> wwc = wk.read_wwc("wind_resource.yaml", crs="EPSG:32632")