IMD

class imdlib.core.IMD(data, cat, start_day, end_day, no_days, lat, lon)

Bases: object

Class to handle binary (.grd) IMD gridded meteorological data. Currently rain, tmin and tmax variable processing is supported.

datanumpy 3D array

Stores information in 3d numpy array. shape is (no_of_days, lon_size, lat_size).

catstr or None

Three possible values. 1. “rain” -> input files are for daily rainfall values 2. “tmin” -> input files are for daily minimum temperature values 3. “tmax” -> input files are for daily maximum tempereature values

start_daystr

starting date in format of <year(4 digit)-month(2 digit)-day(2 digit)> e.g. (‘2018-01-01’)

end_daystr

ending date in format of <year(4 digit)-month(2 digit)-day(2 digit)> e.g. (‘2018-12-31’)

shape : show dimension of an IMD object

get_xarray : return an xarray object from an IMD object

to_netcdf : write an IMD object to a netcdf file

to_csv : write an IMD object to a csv file

to_ascii : write an IMD object to a ASCII/txt file

IMD object

Attributes Summary

shape

Methods Summary

get_xarray()

to_csv([file_name, lat, lon, out_dir])

to_geotiff([file_name, out_dir])

to_netcdf([file_name, out_dir])

Attributes Documentation

shape

Methods Documentation

get_xarray()
to_csv(file_name=None, lat=None, lon=None, out_dir=None)
to_geotiff(file_name=None, out_dir=None)
to_netcdf(file_name=None, out_dir=None)