# Name: ATan2_Ex_02.py
# Description: Calculates the inverse tangent of pixels based
# on (y, x) values from two rasters
# Requirements: Image Analyst Extension
# Import system modules
import arcpy
from arcpy import env
from arcpy.ia import *
# Set environment settings
env.workspace = "C:/iapyexamples/data"
# Set local variables
inRaster1 = "degs"
inRaster2 = "negs"
# Check out the ArcGIS Image Analyst extension license
arcpy.CheckOutExtension("ImageAnalyst")
# Execute ATan2
outATan2 = ATan2(inRaster1, inRaster2)
# Save the output
outATan2.save("C:/iapyexamples/output/outatan2.tif")