Module Expr Str Import alias TryExcept body Import alias handlers ExceptHandler type NameLoad body ImportFrom alias TryExcept body Import alias handlers ExceptHandler type NameLoad body ImportFrom alias Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Num Assign NameStore Str Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr Str If Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Num Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr For NameStore Call NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr For NameStore Call NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr If CompareGt NameLoad Num body Expr Call AttributeLoad NameLoad attr NameLoad
N/A N/A 
Project:       Geothon (https://github.com/MBoustani/Geothon)
File:          Conversion_Tools/extract_shp_feature.py
Description:   This code extracts some features from shapefile features and create a new shapefile
               from extracted features.
Author:        Maziyar Boustani (github.com/MBoustani)
 N/A os N/A N/A N/A ogr N/A N/A N/A ImportError N/A osgeo ogr N/A N/A N/A osr N/A N/A N/A ImportError N/A osgeo osr N/A in_shp ../static_files/shapefile/rivers_lake_centerlines/ne_50m_rivers_lake_centerlines.shp N/A in_shp_datasource N/A N/A ogr Open in_shp N/A srs N/A N/A osr SpatialReference N/A N/A N/A srs ImportFromEPSG 4326 N/A out_shp extracted_feature.shp N/A out_layer_name layer N/A driver N/A N/A ogr GetDriverByName ESRI Shapefile N/A N/A N/A N/A os path exists out_shp N/A N/A N/A N/A driver DeleteDataSource out_shp N/A out_shp_datasource N/A N/A driver CreateDataSource out_shp N/A out_layer N/A N/A out_shp_datasource CreateLayer out_layer_name srs N/A ogr wkbLineString N/A layer_number N/A N/A in_shp_datasource GetLayerCount N/A in_layer N/A N/A in_shp_datasource GetLayerByIndex 0 N/A in_layer_defn N/A N/A in_layer GetLayerDefn N/A num_field_col N/A N/A in_layer_defn GetFieldCount N/A each N/A range num_field_col N/A N/A field N/A N/A in_layer_defn GetFieldDefn each N/A N/A N/A out_layer CreateField field N/A features_number N/A N/A in_layer GetFeatureCount N/A i N/A range features_number N/A N/A in_shp_feature N/A N/A in_layer GetFeature i N/A in_feature_geometry N/A N/A in_shp_feature GetGeometryRef N/A in_feature_length N/A N/A in_feature_geometry Length N/A N/A in_feature_length 20 N/A N/A N/A N/A out_layer CreateFeature in_shp_feature