RHESSysWorkflows  1.33
Variables
PatchToCumulativeValues Namespace Reference

Tool for printing cummulative values of patch-scale RHESSys output variables. More...

Variables

tuple parser = argparse.ArgumentParser(description='Generate cummulative map of patch-scale RHESSys output variables')
 
string help = 'The configuration file.'
 
tuple args = parser.parse_args()
 
 startDate = None
 
 endDate = None
 
list patchDailyFilepaths = []
 
list variables = ['patchID']
 
tuple scenario = os.path.basename( os.path.dirname(patchDailyFilepath) )
 
tuple f = open(patchDailyFilepath)
 
tuple data = RHESSysOutput.readColumnsFromPatchDailyFile(f, variables)
 
dictionary variablesDict = {}
 
 patchIDs = None
 
 variable = None
 
list dataForDate = data[key]
 
dictionary vars = {}
 
list dataForPatch = variablesDict[p]
 
tuple patchIdx = np.where( patchIDs == p )
 
list tmp_data = dataForPatch[var]
 
tuple p_tmp = np.array( dataForPatch[var] )
 

Detailed Description

Tool for printing cummulative values of patch-scale RHESSys output variables.

This software is provided free of charge under the New BSD License. Please see the following license information:

Copyright (c) 2014, University of North Carolina at Chapel Hill All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF NORTH CAROLINA AT CHAPEL HILL BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Author
Brian Miles brian.nosp@m._mil.nosp@m.es@un.nosp@m.c.ed.nosp@m.u

Pre conditions

  1. Configuration file must define the following sections and values: 'GRASS', 'GISBASE' 'RHESSYS', 'PATH_OF_FFMPEG'
  2. The following metadata entry(ies) must be present in the RHESSys section of the metadata associated with the project directory: grass_dbase grass_location grass_mapset

Post conditions

None

Todo:
Add ability to read in two files, accumulate data, and write normalized map (value / max(value))

This software is provided free of charge under the New BSD License. Please see the following license information:

Copyright (c) 2014, University of North Carolina at Chapel Hill All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF NORTH CAROLINA AT CHAPEL HILL BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Author
Brian Miles brian.nosp@m._mil.nosp@m.es@un.nosp@m.c.ed.nosp@m.u

Pre conditions

  1. Configuration file must define the following sections and values: 'GRASS', 'GISBASE' 'RHESSYS', 'PATH_OF_FFMPEG'
  2. The following metadata entry(ies) must be present in the RHESSys section of the metadata associated with the project directory: grass_dbase grass_location grass_mapset

Post conditions

None

Todo:
Add ability to read in two files, accumulate data, and write normalized map (value / max(value))

Variable Documentation

tuple PatchToCumulativeValues.args = parser.parse_args()
tuple PatchToCumulativeValues.data = RHESSysOutput.readColumnsFromPatchDailyFile(f, variables)
list PatchToCumulativeValues.dataForDate = data[key]
list PatchToCumulativeValues.dataForPatch = variablesDict[p]
tuple PatchToCumulativeValues.endDate = None
tuple PatchToCumulativeValues.f = open(patchDailyFilepath)
string PatchToCumulativeValues.help = 'The configuration file.'
tuple PatchToCumulativeValues.p_tmp = np.array( dataForPatch[var] )
tuple PatchToCumulativeValues.parser = argparse.ArgumentParser(description='Generate cummulative map of patch-scale RHESSys output variables')
list PatchToCumulativeValues.patchDailyFilepaths = []
tuple PatchToCumulativeValues.patchIDs = None
tuple PatchToCumulativeValues.patchIdx = np.where( patchIDs == p )
tuple PatchToCumulativeValues.scenario = os.path.basename( os.path.dirname(patchDailyFilepath) )
tuple PatchToCumulativeValues.startDate = None
list PatchToCumulativeValues.tmp_data = dataForPatch[var]
list PatchToCumulativeValues.variable = None
list PatchToCumulativeValues.variables = ['patchID']
dictionary PatchToCumulativeValues.variablesDict = {}
dictionary PatchToCumulativeValues.vars = {}