Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import arcpy
- import os
- ws = arcpy.env.workspace = r'D:BRB Snow CoverSampleTerra'
- Terra_Rasters = arcpy.ListRasters("MOD*")
- matches = 0
- for item1 in Terra_Rasters:
- for item2 in Terra_Rasters:
- print item1
- print item2
- if item1.endswith(item2[32:37]):
- print "Match"
- output = "D:\BRB Snow Cover\Sample\output""\" + str(item1) + '.tif'
- arcpy.gp.Con_sa(item1,item2,output,item1,""Value" =8")
- else:
- print "No"
- matches = matches+1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement