HWRF  trunk@4391
Public Member Functions | Public Attributes | Properties | List of all members
hwrf.hwrftask.HWRFTask Class Reference

The base class of tasks run by the HWRF system. More...

Detailed Description

The base class of tasks run by the HWRF system.

This class represents a task to be run by the HWRF system. It can be configured by an hwrf.config.HWRFConfig object. Internal state information is stored in an produtil.datastore.Datastore. Each task has its own workdir, outdir and scrub flag, as well as its own vitals information.

Execution of a task is done by calling run(), and the products generated by this task can be iterated with products()

Definition at line 25 of file hwrftask.py.

Inheritance diagram for hwrf.hwrftask.HWRFTask:
produtil.datastore.Task produtil.datastore.Datum hwrf.bufrprep.Bufrprep hwrf.copywrf.WRFCopyTask hwrf.ensda.CycleTDRCheck hwrf.ensda.DAEnsemble hwrf.ensda.FromGFSENKF hwrf.ensda.FromPriorCycle hwrf.fcsttask.FcstTask hwrf.gribtask.GRIBTask hwrf.gsi.GSIBase hwrf.gsipost.GSIPost hwrf.hwrfsystem.HWRFForecastPostProcessing hwrf.hwrfsystem.HWRFGSIPostProcessing hwrf.hycom.HYCOMInit hwrf.hycom.HYCOMPost hwrf.init.FGATInit hwrf.init.HWRFInit hwrf.mpipomtc.POMInit hwrf.multistorm.FakeInit hwrf.nhc_products.NHCProducts hwrf.post.PostManyWRF hwrf.post.PostOneWRF hwrf.prep.PrepHybrid hwrf.relocate.Relocation hwrf.relocate.RelocationTask hwrf.tracker.TrackerTask hwrf.wps.WPSTask hwrf.wrf.ExternalWRFTask hwrf.ww3.WW3Init hwrf.ww3.WW3Post

Public Member Functions

def __init__ (self, dstore, conf, section, taskname=None, workdir=None, outdir=None, storminfo=UNSPECIFIED, taskvars=UNSPECIFIED, kwargs)
 Creates an HWRFTask. More...
 
def isfakestorm (self)
 
def ismultistorm (self)
 
def get_workdir (self)
 Returns the directory the class should work in, as set by the "workdir" metadata value. More...
 
def set_workdir (self, val)
 Sets the directory the class should work in. More...
 
def get_outdir (self)
 Gets the directory that should receive output data. More...
 
def set_outdir (self, val)
 Sets the directory that should receive output data. More...
 
def realtime (self)
 Is this job a real-time forecast job? More...
 
def redirect (self)
 Should subprograms' outputs be redirected to separate files?
 
def scrub (self)
 Should temporary files be deleted as soon as they are not needed?
 
def tvset (self, opt, val)
 Sets a taskvar option's value. More...
 
def tvdel (self, opt)
 Deletes an object-local value set by tvset. More...
 
def tvget (self, opt)
 Gets a taskvar's value. More...
 
def tvhave
 Is a taskvar set? More...
 
def taskvars (self)
 The dict of object-local values used for string substitution. More...
 
def confint
 Alias for self.conf.getint for section self.section. More...
 
def confstr
 Alias for self.conf.getstr for section self.section. More...
 
def conffloat
 Alias for self.conf.getfloat for section self.section. More...
 
def confbool
 Alias for self.conf.getbool for section self.section. More...
 
def confget
 Alias for self.conf.get for section self.section. More...
 
def confitems
 Alias for self.conf.items for section self.section. More...
 
def confstrinterp (self, string, section=None, kwargs)
 Alias for self.icstr for backward compatibility. More...
 
def conftimestrinterp (self, string, ftime, atime=None, section=None, kwargs)
 Alias for self.timestr for backward comaptibility. More...
 
def confraw
 Get a raw configuration value before string expansion. More...
 
def icstr (self, string, section=None, kwargs)
 Expands a string in the given conf section. More...
 
def timestr (self, string, ftime, atime=None, section=None, kwargs)
 Expands a string in the given conf section, including time vars. More...
 
def getdir
 Alias for hwrf.config.HWRFConfig.get() for the "dir" section. More...
 
def getexe
 Alias for hwrf.config.HWRFConfig.get() for the "exe" section. More...
 
def getconf (self)
 Returns this HWRFTask's hwrf.config.HWRFConfig object. More...
 
def getsection (self)
 Returns this HWRFTask's section name in the HWRFConfig. More...
 
def log
 Obtain a logging domain. More...
 
def inputiter (self)
 Iterates over all inputs required by this task. More...
 
- Public Member Functions inherited from produtil.datastore.Task
def __init__ (self, dstore, taskname, logger=None, kwargs)
 Task constructor. More...
 
def jlogfile (self)
 returns the jlogfile logger. More...
 
def postmsg (self, message, args, kwargs)
 same as produtil.log.jlogger.info() More...
 
def setstate (self, val)
 Sets the state of this job. More...
 
def getstate (self)
 Returns the job state. More...
 
def strstate (self)
 A string representation of the job state. More...
 
def gettaskname (self)
 Returns the task name part of the database ID, which is the same as the prodname. More...
 
def products (self, args, kwargs)
 Iterate over the products this task produces. More...
 
def log (self)
 Returns the logger object for this task. More...
 
def clean (self)
 Cleans up any unneeded data used by this task. More...
 
def unrun (self)
 Undoes the effect of run(). More...
 
def run (self)
 Performs the work this Task should do and generates all products. More...
 
def is_completed (self)
 Is this task complete? More...
 
def completed (self)
 Read-only property: is this task completed? Same as is_completed() More...
 
def runpart (self)
 Run some of this task's work, deliver some products. More...
 
- Public Member Functions inherited from produtil.datastore.Datum
def __init__ (self, dstore, prodname, category, meta=None, cache=30, location=None, kwargs)
 Datum constructor. More...
 
def __enter__ (self)
 Acquires this object's thread lock. More...
 
def __exit__ (self, etype, evalue, traceback)
 Releases this object's thread lock. More...
 
def validate (self)
 Validates this object's Datastore, prodname and category. More...
 
def getid (self)
 Returns the database ID of this datum. More...
 
def getdatastore (self)
 Returns the datastore of this datum. More...
 
def transaction (self)
 Creates, but does not lock, a Transaction for this datum's datastore. More...
 
def getprodtype (self)
 Returns the product type of this Datum. More...
 
def getprodname (self)
 Returns the product name part of the database ID. More...
 
def getcategory (self)
 Returns the product category part of the database ID. More...
 
def getlocation (self)
 Returns the "location" field of this Datum's database entry. More...
 
def setlocation (self, v)
 Sets the "location" field of this Datum's database entry. More...
 
def __hash__ (self)
 Integer hash function. More...
 
def __str__ (self)
 Human-readable description of this Datum. More...
 
def __repr__ (self)
 Python code-like description of this Datum. More...
 
def __cmp__ (self, other)
 Compares two Datums' prodnames and categories. More...
 
def set_loc_avail (self, loc, avail)
 Sets the location and availability of this Datum in a single transaction. More...
 
def update (self)
 Discards all cached metadata and refreshes it from the Datastore. More...
 
def __getitem__ (self, k)
 Returns the value of the specified metadata key or raises KeyError. More...
 
def meta
 Return the value of a metadata key. More...
 
def get
 Alias for self.meta() Returns the value of the specified metadata key or returns default if it is unset. More...
 
def __setitem__ (self, k, v)
 Sets the value of the specified metadata key. More...
 
def __delitem__ (self, k)
 Deletes the specified metadata key, which must not be "available" or "location". More...
 
def __contains__ (self, k)
 Determines if a metadata key is set. More...
 
def iteritems (self)
 Iterates over all metadata (key,value) pairs for this Datum, including "available" and "location". More...
 

Public Attributes

 storminfo
 The hwrf.storminfo.StormInfo describing the vitals information for the storm processed by this HWRFTask. More...
 

Properties

 workdir
 The directory in which this task should be run. More...
 
 outdir
 The directory in which this task should deliver its final output. More...
 
 conf
 This HWRFTask's hwrf.config.HWRFConfig object. More...
 
 section
 The confsection in self.section for this HWRFTask (read-only) More...
 
- Properties inherited from produtil.datastore.Task
 state
 Read-write property: the job state. More...
 
 taskname
 Read-only property: the name of this task. More...
 
- Properties inherited from produtil.datastore.Datum
 prodname = property(getprodname,None,None,)
 Read-only property, an alias for getprodname(): the product name part of the database ID. More...
 
 category = property(getcategory,None,None,)
 Read-only property, an alias for getcategory(), the category name part of the database ID. More...
 
 prodtype
 Read-only property, an alias for getprodtype(), the product type. More...
 
 did
 Read-only property, an alias for getid(). More...
 
 dstore
 Read-only property, an alias for getdatastore(), the Datastore in which this Datum resides. More...
 
 location
 Read-write property, an alias for getlocation() and setlocation(). More...
 

Constructor & Destructor Documentation

def hwrf.hwrftask.HWRFTask.__init__ (   self,
  dstore,
  conf,
  section,
  taskname = None,
  workdir = None,
  outdir = None,
  storminfo = UNSPECIFIED,
  taskvars = UNSPECIFIED,
  kwargs 
)

Creates an HWRFTask.

Parameters
dstorepassed to Datum: the Datastore object for this Task
confthe conf object for this task
sectionthe conf section for this task
tasknameOptional: the taskname in the datastore. Default: the section name
workdirdirectory in which this task should run. Any value set in the database will override this value.
outdirdirectory where output should be copied. This argument must not be changed throughout the lifetime of the HWRF datstore database file.
storminfothe storm vitals information for the storm this task is running.
taskvarsadditonal variables for string expansion, sent to the taskvars arguments of hwrf.config.HWRFConfig member functions.
kwargspassed to the parent class constructor.

Definition at line 38 of file hwrftask.py.

Member Function Documentation

def hwrf.hwrftask.HWRFTask.confbool (   self,
  opt,
  default = None,
  badtypeok = False,
  section = None,
  morevars = None 
)
def hwrf.hwrftask.HWRFTask.conffloat (   self,
  opt,
  default = None,
  badtypeok = False,
  section = None,
  morevars = None 
)

Alias for self.conf.getfloat for section self.section.

Parameters
optthe option name
sectionOptional: the section. Default: self.section
defaultif specified and not None, then the default is returned if an option has no value or the section does not exist
badtypeokis True, and the conversion fails, and a default is specified, the default will be returned.
morevarsdict of more variables for string expansion

Definition at line 274 of file hwrftask.py.

Referenced by hwrf.hwrftask.HWRFTask.confstr(), hwrf.wps.WPSTask.deliver_products(), hwrf.init.FGATInit.fhr_and_init(), hwrf.gsi.GSIBase.grab_gfs_enkf(), hwrf.gsi.GSIBase.inputiter(), hwrf.hwrfsystem.HWRFForecastPostProcessing.make_extra_trackers(), hwrf.hwrfsystem.HWRFForecastPostProcessing.make_gribber_tracker(), hwrf.hwrfsystem.HWRFForecastPostProcessing.make_nonsatpost(), hwrf.hwrfsystem.HWRFForecastPostProcessing.make_satpost(), hwrf.hwrfsystem.HWRFForecastPostProcessing.make_wrfcopier(), hwrf.bufrprep.Bufrprep.prep_prepbufr(), hwrf.finalmergetask.FinalMergeTask.run_exe(), hwrf.fcsttask.WRFTaskBase.run_exe(), hwrf.fcsttask.WRFAtmos.run_exe(), hwrf.gsi.GSIBase.run_gsi_exe(), and hwrf.nhc_products.NHCProducts.write_namelist().

def hwrf.hwrftask.HWRFTask.confget (   self,
  opt,
  default = None,
  badtypeok = False,
  section = None,
  morevars = None 
)

Alias for self.conf.get for section self.section.

Parameters
optthe option name
sectionOptional: the section. Default: self.section
defaultif specified and not None, then the default is returned if an option has no value or the section does not exist
badtypeokis True, and the conversion fails, and a default is specified, the default will be returned.
morevarsdict of more variables for string expansion

Definition at line 300 of file hwrftask.py.

Referenced by hwrf.hwrftask.HWRFTask.confbool(), and hwrf.post.PostOneWRF.make_control().

def hwrf.hwrftask.HWRFTask.confint (   self,
  opt,
  default = None,
  badtypeok = False,
  section = None,
  morevars = None 
)
def hwrf.hwrftask.HWRFTask.confitems (   self,
  section = None,
  morevars = None 
)

Alias for self.conf.items for section self.section.

Parameters
sectionOptional: the section. Default: self.section.
morevarsvariables for string substitution

Definition at line 312 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.confraw (   self,
  opt,
  default = None,
  section = None 
)

Get a raw configuration value before string expansion.

Returns the raw, uninterpolated value for the specified option, raising an exception if that option is unset. Will not search other sections, and will not search the taskvars, unlike other conf accessors.

Parameters
optthe option of interest
sectionOptional: the section. Default: self.section
defaultOptional: value to return if nothing is found.

Definition at line 338 of file hwrftask.py.

Referenced by hwrf.hwrfsystem.HWRFForecastPostProcessing.make_wrfcopier().

def hwrf.hwrftask.HWRFTask.confstr (   self,
  opt,
  default = None,
  badtypeok = False,
  section = None,
  morevars = None 
)

Alias for self.conf.getstr for section self.section.

Parameters
optthe option name
sectionOptional: the section. Default: self.section
defaultif specified and not None, then the default is returned if an option has no value or the section does not exist
badtypeokis True, and the conversion fails, and a default is specified, the default will be returned.
morevarsdict of more variables for string expansion

Definition at line 261 of file hwrftask.py.

Referenced by hwrf.bufrprep.Bufrprep.__init__(), hwrf.hwrftask.HWRFTask.__init__(), hwrf.ensda.DAEnsemble.__init__(), hwrf.mpipomtc.POMInit.__init__(), hwrf.ensda.CycleTDRCheck.__init__(), hwrf.hwrftask.HWRFTask.confint(), hwrf.relocate.RelocationTask.copy_fixed(), hwrf.relocate.RelocationTask.create_atcf(), hwrf.bufrprep.Bufrprep.deliver_products(), hwrf.hycom.HYCOMInit.find_rtofs_data(), hwrf.wps.Ungrib.get_grib(), hwrf.bufrprep.Bufrprep.grab_bufr(), hwrf.gsi.GSIBase.grab_bufr(), hwrf.gsi.GSIBase.grab_enkf_input(), hwrf.bufrprep.Bufrprep.grab_prepbufr(), hwrf.gsi.GSIBase.inputiter(), hwrf.wps.WPSTask.link_fix(), hwrf.post.PostOneWRF.make_control(), hwrf.coupling.CoupledWRF.make_coupler_namelist(), hwrf.gsi.GSIBase.make_gsi_namelist(), hwrf.hwrfsystem.HWRFForecastPostProcessing.make_wrfcopier(), hwrf.ww3.WW3Init.products(), hwrf.gsipost.GSIPost.run(), hwrf.ww3.WW3Init.run(), hwrf.ww3.WW3Post.run(), hwrf.ensda.FromGFSENKF.run(), hwrf.gsi.GSIBase.run(), hwrf.mpipomtc.POMInit.run_init(), hwrf.fcsttask.AnalysisCycle.simlen(), hwrf.ensda.CycleTDRCheck.tdr_this_cycle(), and hwrf.nhc_products.NHCProducts.write_namelist().

def hwrf.hwrftask.HWRFTask.confstrinterp (   self,
  string,
  section = None,
  kwargs 
)
def hwrf.hwrftask.HWRFTask.conftimestrinterp (   self,
  string,
  ftime,
  atime = None,
  section = None,
  kwargs 
)

Alias for self.timestr for backward comaptibility.

Parameters
stringthe string to expand
ftimethe forecast time
atimeOptional: the analysis time. Default: self.conf.cycle
sectionOptional: the section in which to expand it. Default: self.section.
kwargsmore arguments for string substitution

Definition at line 328 of file hwrftask.py.

Referenced by hwrf.hwrftask.HWRFTask.confstrinterp(), hwrf.gsi.GSIBase.grab_gfs_enkf(), hwrf.gribtask.GRIBTask.products(), and hwrf.prep.PrepHybrid.run_ipiece().

def hwrf.hwrftask.HWRFTask.get_outdir (   self)

Gets the directory that should receive output data.

This is in the "outdir" metadata value.

Definition at line 159 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.get_workdir (   self)

Returns the directory the class should work in, as set by the "workdir" metadata value.

Definition at line 141 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.getconf (   self)

Returns this HWRFTask's hwrf.config.HWRFConfig object.

Definition at line 410 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.getdir (   self,
  opt,
  default = None,
  morevars = None 
)
def hwrf.hwrftask.HWRFTask.getexe (   self,
  opt,
  default = None,
  morevars = None 
)

Alias for hwrf.config.HWRFConfig.get() for the "exe" section.

Parameters
optthe option name
defaultOptional: default value if nothing is found.
morevarsOptional: more variables for string substitution

Definition at line 403 of file hwrftask.py.

Referenced by hwrf.relocate.Merge.blend_gsi(), hwrf.tracker.TrackerTask.concat_grib(), hwrf.finalmergetask.FinalMergeTask.convert_wrfinput2bin(), hwrf.nhc_products.NHCProducts.deliver_wrfdiag(), hwrf.finalmergetask.FinalMergeTask.final_merge(), hwrf.finalmergetask.FinalMergeTask.finalmerge2netcdf(), hwrf.hycom.HYCOMInit.find_rtofs_data(), hwrf.wps.Ungrib.get_grib(), hwrf.relocate.Merge.inter_2to1ges(), hwrf.relocate.Merge.inter_3to2(), hwrf.multistorm.WRFAtmosMultiStorm.make_namelist(), hwrf.fcsttask.WRFTaskBase.make_namelist(), hwrf.fcsttask.RealNMM.make_namelist(), hwrf.copywrf.WRFCopyTask.ncks_path(), hwrf.ww3.WW3Post.ncks_path(), hwrf.bufrprep.Bufrprep.prep_prepbufr(), hwrf.ensda.CycleTDRCheck.readensdatrigger(), hwrf.bufrprep.Bufrprep.readtdrstmid(), hwrf.bufrprep.Bufrprep.readtdrtime(), hwrf.relocate.Stage1.relocate_storm(), hwrf.relocate.Stage2.relocate_storm(), hwrf.relocate.Merge.relocate_storm(), hwrf.fcsttask.WRFAnl4Trak.retime_wrfout(), hwrf.gsipost.GSIPost.run(), hwrf.ww3.WW3Init.run(), hwrf.nhc_products.NHCProducts.run(), hwrf.post.PostOneWRF.run(), hwrf.ww3.WW3Post.run(), hwrf.wps.Geogrid.run(), hwrf.wps.Ungrib.run(), hwrf.wps.Metgrid.run(), hwrf.tracker.TrackerTask.run(), hwrf.coupling.CoupledWRF.run_exe(), hwrf.finalmergetask.FinalMergeTask.run_exe(), hwrf.fcsttask.WRFTaskBase.run_exe(), hwrf.finalmergetask.FinalMergeTask.run_ext(), hwrf.relocate.RelocationTask.run_ext(), hwrf.gsi.GSIBase.run_gsi_exe(), hwrf.prep.PrepHybrid.run_ipiece(), hwrf.relocate.Stage3.update_3dvar(), hwrf.relocate.Merge.update_3dvar(), and hwrf.gsi.GSIBase.wrfout_copier().

def hwrf.hwrftask.HWRFTask.getsection (   self)

Returns this HWRFTask's section name in the HWRFConfig.

Definition at line 417 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.icstr (   self,
  string,
  section = None,
  kwargs 
)

Expands a string in the given conf section.

Given a string, expand it as if it was a value in the specified conf section. Makes this objects tcvitals, if any, available via the "vit" variable while interpolating strings.

Parameters
stringthe string to expand
sectionOptional: the section in which to expand it. Default: self.section.
kwargsmore arguments for string substitution

Definition at line 351 of file hwrftask.py.

Referenced by hwrf.gsi.GSIBase.__init__(), hwrf.mpipomtc.POMInit.__init__(), hwrf.multistorm.RealInit.add_wrfinput(), hwrf.hwrftask.HWRFTask.confstrinterp(), hwrf.gsi.GSIBase.grab_fix_parm(), hwrf.hycom.HYCOMInit.make_products(), hwrf.ww3.WW3Init.run(), hwrf.hycom.HYCOMInit.run(), hwrf.ww3.WW3Post.run(), and hwrf.bufrprep.Bufrprep.set_tdrstatus().

def hwrf.hwrftask.HWRFTask.inputiter (   self)

Iterates over all inputs required by this task.

Iterates over dict-like objects suitable for input to hwrf.input.InputSource.get. Each object contains the following keywords:

  • dataset: string name of the dataset (gfs, gdas1, gefs, enkf, etc.)
  • item: string name of the object (ie.: gfs_sf, gfs_sfcanl, bufr)
  • atime: self.conf.cycle
  • ftime: only present when relevant: the forecast time, in a format accepted by to_datetime_rel
  • enkfmem: only present when relevant: the ENKF member ID
  • obstype: only present when relevant: the bufr data type. Other keywords may be present if needed. They will be passed on by hwrf.input.InputSource for string replacement.

Definition at line 436 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.isfakestorm (   self)
def hwrf.hwrftask.HWRFTask.ismultistorm (   self)
def hwrf.hwrftask.HWRFTask.log (   self,
  subdom = None 
)

Obtain a logging domain.

Creates or returns a logging.Logger. If subdom is None or unspecified, returns a cached logger for this task's logging domain. Otherwise, returns a logger for the specified subdomain of this task's logging domain.

Parameters
subdomOptional: the desired logging domain

Definition at line 425 of file hwrftask.py.

Referenced by hwrf.init.HWRFInit.__init__(), hwrf.post.PostOneWRF.__init__(), hwrf.post.PostManyWRF.__init__(), hwrf.init.FGATInit.__init__(), hwrf.multistorm.RealInit.add_wrfinput(), hwrf.relocate.Stage3.anl_4x(), hwrf.relocate.Stage3.anl_bogus_10m(), hwrf.relocate.Stage3.anl_cs_10m(), hwrf.relocate.Merge.blend_gsi(), hwrf.gribtask.GRIBTask.call_completed_callbacks(), hwrf.tracker.TrackerTask.call_completed_callbacks(), hwrf.post.PostOneWRF.can_run(), hwrf.nhc_products.NHCProducts.canrun(), hwrf.coupling.CoupledWRF.check_all_inputs(), hwrf.relocate.Stage1.check_atcf_hours(), hwrf.wps.Ungrib.check_outfiles(), hwrf.post.PostOneWRF.check_post(), hwrf.relocate.Stage1.check_prior_cycle(), hwrf.relocate.Merge.check_storm_radius(), hwrf.copywrf.WRFCopyTask.compression_copier(), hwrf.tracker.TrackerTask.concat_grib(), hwrf.finalmergetask.FinalMergeTask.convert_wrfinput2bin(), hwrf.relocate.Stage1.copy_ensda_track(), hwrf.relocate.RelocationTask.copy_fixed(), hwrf.relocate.Stage1.copy_hdas(), hwrf.finalmergetask.FinalMergeTask.copy_inputs(), hwrf.relocate.RelocationTask.copy_inputs(), hwrf.relocate.Stage1.copy_namelist(), hwrf.gsi.GSIBase.copy_wrf_inout(), hwrf.gsi.FGATGSI.copy_wrf_inout(), hwrf.relocate.RelocationTask.create_atcf(), hwrf.relocate.Stage2.create_nest(), hwrf.relocate.Stage2.create_track(), hwrf.relocate.Stage3.create_track(), hwrf.relocate.Stage3.cycled_or_weak_run(), hwrf.copywrf.WRFCopyTask.decompression_copier(), hwrf.relocate.RelocationTask.delete_temp(), scripts.exhwrf_output.Deliverer.deliver_file(), hwrf.copywrf.WRFCopyTask.deliver_group(), hwrf.nhc_products.NHCProducts.deliver_outlist(), hwrf.mpipomtc.POMInit.deliver_products(), hwrf.bufrprep.Bufrprep.deliver_products(), hwrf.wps.WPSTask.deliver_products(), hwrf.finalmergetask.FinalMergeTask.deliver_products(), hwrf.relocate.RelocationTask.deliver_products(), hwrf.gsi.GSIBase.deliver_products(), hwrf.fcsttask.WRFAnl.deliver_products(), hwrf.fcsttask.WRFAnl4Trak.deliver_products(), hwrf.fcsttask.AnalysisCycle.deliver_products(), hwrf.nhc_products.NHCProducts.deliver_wrfdiag(), hwrf.relocate.Stage3.ensda_relocate_run(), hwrf.init.FGATInit.fhr_and_init(), hwrf.finalmergetask.FinalMergeTask.final_merge(), hwrf.finalmergetask.FinalMergeTask.finalmerge2netcdf(), hwrf.hycom.HYCOMInit.find_rtofs_data(), hwrf.multistorm.FakeInit.geodat(), hwrf.gribtask.GRIBTask.get_data(), hwrf.relocate.Stage3.get_ghost(), hwrf.wps.Ungrib.get_grib(), hwrf.mpipomtc.POMInit.get_inputs(), hwrf.ensda.FromPriorCycle.get_product(), hwrf.bufrprep.Bufrprep.getstormid(), hwrf.gsi.GSIBase.grab_fix_parm(), hwrf.gsi.GSIBase.grab_gfs_enkf(), hwrf.tracker.TrackerTask.grab_gribs(), hwrf.gsi.FGATGSI.grab_more_inputs(), hwrf.bufrprep.Bufrprep.grab_obstype_section(), hwrf.gsi.GSIBase.grab_obstype_section(), hwrf.bufrprep.Bufrprep.grab_prepbufr(), hwrf.gsi.GSIBase.grab_prepbufr(), hwrf.gsi.GSIBase.grab_wrf_enkf(), hwrf.relocate.Stage1.guess_track(), hwrf.fcsttask.RealNMM.initial_prerun(), hwrf.prep.PrepHybrid.input_at(), hwrf.wps.Ungrib.input_at(), hwrf.relocate.Merge.inter_2to1(), hwrf.relocate.Merge.inter_2to1ges(), hwrf.relocate.Stage3.inter_2to2(), hwrf.relocate.Merge.inter_2to2(), hwrf.relocate.Stage3.inter_2to2_again(), hwrf.relocate.Merge.inter_2to3(), hwrf.relocate.Merge.inter_2to6(), hwrf.relocate.Merge.inter_3to2(), hwrf.relocate.Stage3.inter_4to6(), hwrf.wps.WPSTask.io_suffix(), hwrf.coupling.CoupledWRF.link_all_inputs(), hwrf.wps.WPSTask.link_fix(), hwrf.post.PostOneWRF.link_fix(), hwrf.wps.WPSTask.link_geogrid(), hwrf.tracker.TrackerTask.link_grib(), hwrf.fcsttask.FcstTask.link_input(), hwrf.relocate.RelocationTask.make_analysis_namelist(), hwrf.post.PostOneWRF.make_control(), hwrf.coupling.CoupledWRF.make_coupler_namelist(), hwrf.gsi.GSIBase.make_diag_files(), hwrf.relocate.RelocationTask.make_ghost_namelist(), hwrf.gsi.GSIBase.make_gsi_namelist(), hwrf.multistorm.WRFAtmosMultiStorm.make_namelist(), hwrf.fcsttask.WRFTaskBase.make_namelist(), hwrf.fcsttask.RealNMM.make_namelist(), hwrf.hycom.HYCOMInit.make_products(), hwrf.gribtask.GRIBTask.make_products(), hwrf.wps.Geogrid.make_products(), hwrf.fcsttask.AnalysisCycle.make_products(), hwrf.fcsttask.WRFAtmos.make_wrf(), hwrf.fcsttask.AnalysisCycle.make_wrf(), hwrf.relocate.Stage1.merge_nest(), hwrf.relocate.Stage2.merge_nests(), hwrf.relocate.Stage1.pert_ct(), hwrf.relocate.Stage3.pert_ct_gfs(), hwrf.relocate.Stage3.pert_ct_weak(), hwrf.bufrprep.Bufrprep.prep_prepbufr(), hwrf.ww3.WW3Init.products(), hwrf.relocate.Stage3.products(), hwrf.ensda.CycleTDRCheck.read_trigger_file(), hwrf.ensda.CycleTDRCheck.readensdatrigger(), hwrf.bufrprep.Bufrprep.readtdrstmid(), hwrf.bufrprep.Bufrprep.readtdrtime(), hwrf.relocate.Stage1.relocate_storm(), hwrf.relocate.Stage2.relocate_storm(), hwrf.relocate.Merge.relocate_storm(), hwrf.fcsttask.WRFAnl4Trak.retime_wrfout(), hwrf.relocate.RelocationTask.rinfo(), hwrf.gsipost.GSIPost.run(), hwrf.mpipomtc.POMInit.run(), hwrf.ww3.WW3Init.run(), hwrf.hycom.HYCOMInit.run(), hwrf.finalmergetask.FinalMergeTask.run(), hwrf.prep.PrepHybrid.run(), hwrf.bufrprep.Bufrprep.run(), hwrf.nhc_products.NHCProducts.run(), hwrf.copywrf.WRFCopyTask.run(), hwrf.post.PostOneWRF.run(), hwrf.ww3.WW3Post.run(), hwrf.hycom.HYCOMPost.run(), hwrf.ensda.FromGFSENKF.run(), hwrf.tracker.TrackerView.run(), hwrf.wps.Geogrid.run(), hwrf.relocate.Stage1.run(), hwrf.gsi.GSIBase.run(), hwrf.wps.Ungrib.run(), hwrf.wps.Metgrid.run(), hwrf.tracker.TrackerTask.run(), hwrf.relocate.Stage2.run(), hwrf.relocate.Stage3.run(), hwrf.relocate.Merge.run(), hwrf.coupling.CoupledWRF.run_exe(), hwrf.finalmergetask.FinalMergeTask.run_exe(), hwrf.fcsttask.WRFTaskBase.run_exe(), hwrf.fcsttask.RealNMM.run_exe(), hwrf.finalmergetask.FinalMergeTask.run_ext(), hwrf.relocate.RelocationTask.run_ext(), hwrf.gsi.GSIBase.run_gsi_exe(), hwrf.copywrf.WRFCopyTask.run_helper(), hwrf.gribtask.GRIBTask.run_helper(), hwrf.mpipomtc.POMInit.run_init(), hwrf.init.HWRFInit.run_init_after_anl(), hwrf.prep.PrepHybrid.run_ipiece(), hwrf.init.HWRFInit.run_real_bdy(), hwrf.init.HWRFInit.run_through_anl(), hwrf.prep.PrepHybrid.runpart(), hwrf.coupling.CouplingStatus.set(), hwrf.gribtask.GRIBTask.set_data(), hwrf.bufrprep.Bufrprep.set_tdrstatus(), hwrf.ensda.AlwaysRunENSDA.should_run_ensda(), hwrf.relocate.Stage1.split_wrf(), hwrf.ensda.CycleTDRCheck.tdr_this_cycle(), hwrf.bufrprep.Bufrprep.tdrdump(), hwrf.gribtask.GRIBTask.uncomplete(), hwrf.wps.WPSTask.undeliver_products(), hwrf.hycom.HYCOMPost.unrun(), hwrf.relocate.Stage3.update_3dvar(), hwrf.relocate.Merge.update_3dvar(), hwrf.wrf.ExternalWRFTask.update_state(), hwrf.relocate.Stage3.weak_cold_run(), hwrf.relocate.Stage2.wrf_split(), hwrf.relocate.RelocationTask.wrfanl_at_time(), hwrf.relocate.Stage3.wrfanl_at_time(), hwrf.relocate.RelocationTask.wrfinput_at_time(), hwrf.relocate.Stage3.wrfinput_at_time(), hwrf.gsi.GSIBase.wrfout_copier(), hwrf.post.PostManyWRF.wrftask(), hwrf.bufrprep.Bufrprep.write_vitals(), hwrf.gsi.GSIBase.write_vitals(), and hwrf.relocate.RelocationTask.write_vitals().

def hwrf.hwrftask.HWRFTask.realtime (   self)

Is this job a real-time forecast job?

Is this job running an actual, real-time forecast for an event happening now? This is different than self.conf.realtime: it allows this job's config section to locally override the value.

Definition at line 180 of file hwrftask.py.

Referenced by hwrf.bufrprep.Bufrprep.deliver_products(), hwrf.wps.Ungrib.get_grib(), hwrf.gsi.GSIBase.grab_gfs_enkf(), hwrf.gsi.GSIBase.grab_obstype_section(), hwrf.gsi.GSIBase.grab_wrf_enkf(), hwrf.ww3.WW3Init.products(), hwrf.bufrprep.Bufrprep.run(), hwrf.prep.PrepHybrid.run_ipiece(), and hwrf.ensda.CycleTDRCheck.tdr_this_cycle().

def hwrf.hwrftask.HWRFTask.set_outdir (   self,
  val 
)

Sets the directory that should receive output data.

Sets the "outdir" metadata value.

Parameters
valthe new output directory

Definition at line 167 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.set_workdir (   self,
  val 
)

Sets the directory the class should work in.

This sets the "workdir" metadata value.

Parameters
valthe new work directory

Definition at line 149 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.taskvars (   self)
def hwrf.hwrftask.HWRFTask.timestr (   self,
  string,
  ftime,
  atime = None,
  section = None,
  kwargs 
)

Expands a string in the given conf section, including time vars.

Expands a string in the given conf section (default: self.section), and includes forecast and analysis time (default: conf.cycle) information in the variables that can be expanded. The mandatory ftime argument is the forecast time which will be used to expand values such as fHH, fYMDH, etc. The optional atime will be used to expand aHH, aYMDH, etc., and the two will be used together for forecast minus analysis fields like fahr. See hwrf.config.timestrinterp for details

As with self.icstr, this class's vitals are available via the "vit" variable while interpolating strings.

Parameters
stringthe string to expand
ftimethe forecast time
atimeOptional: the analysis time. Default: self.conf.cycle
sectionOptional: the section in which to expand it. Default: self.section.
kwargsmore arguments for string substitution

Definition at line 367 of file hwrftask.py.

Referenced by hwrf.ww3.WW3Init.__init__(), hwrf.hwrftask.HWRFTask.conftimestrinterp(), hwrf.mpipomtc.POMInit.get_inputs(), hwrf.hycom.HYCOMInit.make_products(), and hwrf.mpipomtc.POMInit.run().

def hwrf.hwrftask.HWRFTask.tvdel (   self,
  opt 
)

Deletes an object-local value set by tvset.

Parameters
optthe name of the taskvar to delete

Definition at line 215 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.tvget (   self,
  opt 
)

Gets a taskvar's value.

Returns the value of an object-local (taskvar) option set by tvset.

Parameters
optthe taskvar whose value should be returned

Definition at line 221 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.tvhave (   self,
  opt = UNSPECIFIED 
)

Is a taskvar set?

If an option is specified, determines if the given option has an object-local (taskvar) value. If no option is specified, returns True if ANY object-local values (taskvars) exist for any options.

Parameters
optOptional: the name of the taskvar being checked.

Definition at line 229 of file hwrftask.py.

def hwrf.hwrftask.HWRFTask.tvset (   self,
  opt,
  val 
)

Sets a taskvar option's value.

Sets an object-local (taskvar) value for option "opt" to value "val". This will override config settings from the HWRFConfig object. These are sent into the taskvars= parameter to the various HWRFConfig member functions (hence the "tv" in "tvset").

Parameters
optthe name of the taskvar
valthe string value of the option

Definition at line 200 of file hwrftask.py.

Referenced by hwrf.hwrftask.HWRFTask.__init__().

Member Data Documentation

hwrf.hwrftask.HWRFTask.storminfo

Property Documentation

hwrf.hwrftask.HWRFTask.conf
static
hwrf.hwrftask.HWRFTask.outdir
static
hwrf.hwrftask.HWRFTask.section
static
hwrf.hwrftask.HWRFTask.workdir
static

The documentation for this class was generated from the following file: