Please post the top portion of your code where you parse out the input parameters.
# ~~ execute() ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # def execute(self, P, messages): """ EXECUTE() calls ImpactScoreRasters.ImpactScoreRasters in Bungee's executing directory. """ pK = self.paramOrder import arcpy # process parameters analysis = arcpy.Describe(P[pK['analysis']].value).catalogPath outPad = arcpy.Describe(P[pK['outPad']].value).catalogPath outRoad = arcpy.Describe(P[pK['outRoad']].value).catalogPath outPipe = arcpy.Describe(P[pK['outPipe']].value).catalogPath usePadFootprint = P[pK['usePadFootprint']].value
# ~~ __getParameterInfo__() ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # def getParameterInfo(self): """Define parameter definitions""" import arcpy # input analysis object (pickled file) analysis = arcpy.Parameter( displayName = 'Analysis Object File', name = 'analysis', datatype = 'File', parameterType = 'Required', direction = 'Input' ) # Output Pad Raster outPad = arcpy.Parameter( displayName = 'Output Pad Raster', name = 'outPad', datatype= 'Raster Dataset', parameterType = 'Required', direction = 'Output' ) # Output Road Raster outRoad = arcpy.Parameter( displayName = 'Output Road Raster', name = 'outRoad', datatype= 'Raster Dataset', parameterType = 'Required', direction = 'Output' ) # Output Pipe Raster outPipe = arcpy.Parameter( displayName = 'Output Pipeline Raster', name = 'outPipe', datatype= 'Raster Dataset', parameterType = 'Required', direction = 'Output' ) # Use Pad Footprint Flag usePadFootprint = arcpy.Parameter( displayName = 'Use Pad Footprint?', name = 'usePadFootprint', datatype = 'Boolean', parameterType = 'Optional', direction = 'Input' ) usePadFootprint.value = False # finish parameters = [ analysis, outPad, outRoad, outPipe, usePadFootprint ] return parameters
Přihlášení členové mohou přispívat, sledovat aktualizace a další. Jste tu noví? Zaregistrujte si bezplatný účet.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.