Résumé
Returns a WGS84 UTM zone spatial reference from lat, long coordinates.
Discussion
This function can be used to find the proper spatial reference to be used when creating a mosaic dataset for UAV or UAS images.
Syntaxe
GetUTMFromLocation (longitude, latitude)
Paramètre | Explication | Type de données |
longitude | The longitude of the point. | Double |
latitude | The latitude of the point. | Double |
Valeur renvoyée
Type de données | Explication |
SpatialReference | The spatial reference of the lat, long location. The spatial reference will be returned as a WGS84 UTM zone SpatialReference. The name of the spatial reference will be in the form WGS_1984_UTM_Zone_XXH. The XX indicates the UTM zone number. The H indicates the hemisphere, N for the northern hemisphere, or S for the southern hemisphere. |
Exemple de code
GetUTMFromLocation example
Returns the WGS spatial reference name, based on the latitude and longitude.
import arcpy
sr = arcpy.GetUTMFromLocation(-100.9, 40)
print(sr.name)