GeoTagged Photos To Points (Data Management)

License Level:BasicStandardAdvanced

Summary

Creates points from the x-, y-, and z-coordinates stored in geotagged photos. Optionally adds photo files to features in the output feature class as geodatabase attachments.

Illustration

GeoTagged Photos To Points illustration

Usage

Syntax

GeoTaggedPhotosToPoints_management (Input_Folder, Output_Feature_Class, {Invalid_Photos_Table}, {Include_Non-GeoTagged_Photos}, {Add_Photos_As_Attachments})
ParameterExplanationData Type
Input_Folder

The folder where photo files are located. This folder is scanned recursively for photo files; any photos in the base level of the folder, as well as in any subfolders, will be added to the output.

Folder
Output_Feature_Class

The output point feature class.

Feature Class
Invalid_Photos_Table
(Optional)

The optional output table that will list any photo files in the input folder with invalid Exif metadata or empty GPS coordinates.

If no path is specified, this table will not be created.

Table
Include_Non-GeoTagged_Photos
(Optional)

Specifies if all photo files should be added as records to the output feature class or only those with valid GPS coordinates.

  • ALL_PHOTOS All photo files will be added as records to the output feature class. If a photo file does not have GPS coordinate information, it will be added as a record with null geometry. This is the default.
  • ONLY_GEOTAGGED Only photo files with valid GPS coordinate information will have records in the output feature class.
Boolean
Add_Photos_As_Attachments
(Optional)

Specifies if photo files will be added to the output feature class as geodatabase attachments.

LicenseLicense:

Adding attachments requires at minimum an ArcGIS for Desktop Standard license, and the output feature class must be in a version 10 or higher geodatabase.

  • ADD_ATTACHMENTS Photo files will be added to the output feature class records as geodatabase attachments. Geodatabase attachments are copied internally to the geodatabase. This is the default.
  • NO_ATTACHMENTS Photo files will not be added to the output feature class records as geodatabase attachments.
Boolean

Code Sample

GeoTaggedPhotosToPoints example (Python window)

The following Python window snippet demonstrates how to use the GeoTaggedPhotosToPoints tool.

import arcpy
arcpy.GeoTaggedPhotosToPoints_management("c:/data/photos", "c:/data/city.gdb/photo_points", "", "ONLY_GEOTAGGED", "ADD_ATTACHMENTS")
GeoTaggedPhotosToPoints example (stand-alone script)

The following script demonstrates how to use the GeoTaggedPhotosToPoints tool.

"""Name: GeoTaggedPhotosToPoints example
Description: Convert a folder of photos to points, then perform a buffer
""" 

# Import system modules
import arcpy
from arcpy import env
 
# Set environment settings
env.workspace = "C:/data"
 
# Set local variables
inFolder = "photos"
outFeatures = "city.gdb/photos_points"
badPhotosList = "city.gdb/photos_noGPS"
photoOption = "ONLY_GEOTAGGED"
attachmentsOption = "ADD_ATTACHMENTS"

buffers = "city.gdb/photos_points_buffer"
bufferDist = "1 Miles"

arcpy.GeoTaggedPhotosToPoints_management(inFolder, outFeatures, badPhotosList, photoOption, attachmentsOption)
arcpy.Buffer_analaysis(outFeatures, buffers, bufferDist)

Environments

Related Topics

Licensing Information

ArcGIS for Desktop Basic: Limited
ArcGIS for Desktop Standard: Yes
ArcGIS for Desktop Advanced: Yes
5/7/2015