EcohydroLib  1.29
Variables
GetCatchmentShapefileForHYDRO1kBasins Namespace Reference

Extract tile for HYDRO1k digital elevation model (DEM) stored locally. More...

Variables

tuple parser = argparse.ArgumentParser(description='Get shapefile for the drainage area of an NHDPlus2 streamflow gage')
 
string help = 'The configuration file'
 
tuple args = parser.parse_args()
 
tuple cmdline = GenericMetadata.getCommandLine()
 
 configFile = None
 
tuple context = Context(args.projectDir, configFile)
 
 outfile = args.outfile
 
string shapeFilename = "%s.shp"
 
tuple shapeFilepath = os.path.join(context.projectDir, shapeFilename)
 
tuple asset = AssetProvenance(GenericMetadata.MANIFEST_SECTION)
 

Detailed Description

Extract tile for HYDRO1k digital elevation model (DEM) stored locally.

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

Copyright (c) 2013, 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: 'GDAL/OGR', 'PATH_OF_OGR2OGR' 'HYDRO1k', 'PATH_OF_HYDRO1K_BAS' 'HYDRO1k', 'HYDRO1k_BAS_LAYER_NAME'

Post conditions

  1. Will write the following entry(ies) to the manifest section of metadata associated with the project directory: study_area_shapefile [the name of the catchment shapefile]

Usage:

1 GetCatchmentShapefileForHYDRO1kBasins.py -p /path/to/project_dir -b <basin1> <basin2> ... <basinN>
Note
EcohydroLib configuration file must be specified by environmental variable 'ECOHYDROWORKFLOW_CFG', or -i option must be specified.

Variable Documentation

tuple GetCatchmentShapefileForHYDRO1kBasins.args = parser.parse_args()
tuple GetCatchmentShapefileForHYDRO1kBasins.asset = AssetProvenance(GenericMetadata.MANIFEST_SECTION)
tuple GetCatchmentShapefileForHYDRO1kBasins.cmdline = GenericMetadata.getCommandLine()
GetCatchmentShapefileForHYDRO1kBasins.configFile = None
tuple GetCatchmentShapefileForHYDRO1kBasins.context = Context(args.projectDir, configFile)
string GetCatchmentShapefileForHYDRO1kBasins.help = 'The configuration file'
string GetCatchmentShapefileForHYDRO1kBasins.outfile = args.outfile
tuple GetCatchmentShapefileForHYDRO1kBasins.parser = argparse.ArgumentParser(description='Get shapefile for the drainage area of an NHDPlus2 streamflow gage')
string GetCatchmentShapefileForHYDRO1kBasins.shapeFilename = "%s.shp"
tuple GetCatchmentShapefileForHYDRO1kBasins.shapeFilepath = os.path.join(context.projectDir, shapeFilename)