|
POST
|
Hi! Im having some 10-15 rasters consisting of different soils which I want to be only one raster file. Im having some problems finding out how to proceed as the mosaic operators doesn´t seem to work. The values are just 1 where there this soil type occur, eg. gleysol - 1. The rest is no data. The Cell Statistics Tool calculates stats cell by cell stats across a list of rasters. The MAXIMUM option for that tool sounds like what you're looking for. Be sure and check the box to ignore NODATA cells and the cells that have a NODATA in the stack will still come through to the output, as long as there is a data cell in the stack of inputs.
... View more
01-10-2013
08:32 PM
|
0
|
0
|
1694
|
|
POST
|
PLEASE HELP URGENT - Is there anyone at all who can help with this? I wrote a script based on the Extract Value To Points tool but it doesn't work properly. You have incorrect syntax for ExtractValuesToPoints. You need to add the toolbox name after it if you prefix the tool name with arcpy. I'm pretty sure your script is failing (the tool is not running). You are getting a python error which is not getting printed by your except block. There are good examples in the online help on how to use python exceptions to capture both kinds of errors and report more helpful messages.
# script to extract raster values to point shapefile
# adapted by Scott MacDonald Kingston University k0848626 GSM655Programming Asssignment C
# import system modules
import arcpy
from arcpy import env
from arcpy.sa import *
# get user supplied path, layers and fields
path = arcpy.GetParameterAsText(0)
arcpy.env.workspace = path
# in Feature Layer is Confluence_Pts
in_point_features = arcpy.GetParameterAsText(1)
# in Raster Layer is DEM
in_raster = arcpy.GetParameterAsText(2)
# out Feature Class
out_point_features = arcpy.GetParameterAsText(3)
# error trapping measures
try:
# check out spatial analyst extension
arcpy.CheckOutExtension("Spatial")
# run the ExractValuesToPoints tool
arcpy.ExtractValuesToPoints_sa(in_point_features, in_raster, out_point_features)
# because of your "from arcpy.sa import *" above you could perhaps do this too:
# ExtractValuesToPoints(in_point_features, in_raster, out_point_features)
# check in spatial analyst extension
arcpy.CheckInExtension("Spatial")
except Exception, msg:
print arcpy.GetMessages() # ArcGIS tool messages
print "Python errors:\n",str(msg) # python errors
... View more
01-10-2013
08:08 PM
|
0
|
0
|
1210
|
|
POST
|
Batch is an older functionality that does not work with ModelBuilder. I recommend instead creating a new model with an iterator and embedding your model inside it. This has the added benefit that you can use ModelBuilder to name the outputs using model variables, instead of having to create and validate each output dataset name.
... View more
01-10-2013
07:37 PM
|
0
|
0
|
2039
|
|
POST
|
My advice is to do this process interactively and look at the results window. "Copy As Python Snippet" is your friend!
... View more
01-10-2013
08:22 AM
|
0
|
0
|
3235
|
|
POST
|
I think the root of your problems may be this line:
dbo_GeocodeAddresses3 = "\\\\MyDrive\\ArcGIS\\Default.gdb\\dbo_GeocodeAddresses3.shp" You can't have a shapefile inside a geodatabase; this may be messing up your parameter validation and adding .shp to the output feature class name. Just a tip, try "raw" strings to make it easier to copy and paste paths into code.
arcpy.env.workspace = r"\\MyDrive\ArcGIS\Default.gdb"
... View more
01-10-2013
04:44 AM
|
0
|
0
|
3235
|