This module includes the poets base class Poet.
Bases: object
POETS base class.
Provides methods to download and resample data using parameters as defined in this class. Resampled outputfiles will be saved as NetCDF4 files.
| Parameters: | rootpath : str
regions : list of str, optional
spatial_resolution : float, optional
temporal_resolution : str, optional
start_date : datetime.datetime, optional
nan_value : int
shapefile : str, optional
delete_rawdata : bool, optional
|
|---|
Attributes
| rootpath | (str) path to the directory where data should be stored |
| regions | (list of str) Identifier of the region in the shapefile. |
| spatial_resolution | (float) Spatial resolution in degree. |
| temporal_resolution | (str) Temporal resolution of the data. |
| tmp_path | (str) Path where temporary files and original files are stored and downloaded. |
| data_path | (str) Path where resampled NetCDF file is stored. |
| nan_value | (int) NaN value to use, defaults to -99. |
| start_date | (datetime.datetime) First date of the dataset. |
| shapefile | (str) Path to shape file. |
| sources | (dict of poets.io.BasicSource objects) Sources used by poets given as BasicSource class. |
| delete_rawdata | (bool) Original files will be deleted from tmp_path if True. |
Methods
Creates BasicSource class and adds it to Poet.sources.
| Parameters: | name : str
filename : str
filedate : dict
temp_res : str
host : str
protocol : str
username : str, optional
password : str, optional
port : int, optional
directory : str, optional
dirstruct : list of strings
begin_date : datetime.date, optional
variables : list of strings, optional
nan_value : int, float, optional
|
|---|
Starts download and resampling of input data for sources as added to Poets.sources.
| Parameters: | begin : datetime, optional
end : datetime, optional
delete_rawdata : bool, optional
|
|---|