I'm attempting to complete a batch mosaic operation in ArcMap 10.4.1 Python window. I need to run the Mosaic tool about 80 times for sets of three rasters. Basically I want the second and third raster to mosaic to the first raster with all of the default mosaic properties. My code to do this is pasted below, but after playing around with the inputs for the Mosaic Management tool I keep getting back a parsing error SyntaxError in the line where the Mosaic operation occurs.
# Name: Batch Extract by Mask
... # Description: Iteratively calculate extracts the flow velocity of cells
... # Requires spatial analyst
... # MAKE SURE RASTERS FOR Connectivity ARE LOADED IN THE MXD TABLE OF CONTENTS
...
... # Import system modules
... import arcpy
... from arcpy import env
... from arcpy.sa import *
... import math
... # Set environment settings
... env.workspace = "C:\Subbasin Connectivity Flow Time"
... # Check the ArcGIS Spatial Analyst extension license
... arcpy.CheckOutExtension("Spatial")
... count = 1
... # Run for each raster in the directory
... while count < 80:
... # Execute times flow direction calculation
... name1 = "Day72Subbasin" + str(count) + " Bin 1.tif"
... Bin1 = Raster(name1)
... name2 = "Day72Subbasin" + str(count) + " Bin 2.tif"
... Bin2 = Raster(name2)
... name3 = "Day72Subbasin" + str(count) + " Bin 3.tif"
... Bin3 = Raster(name3)
... arcpy.Mosaic_management(Bin2;Bin3,Bin1,"LAST","FIRST","0", "", "NONE", "", "")
... count = count + 1
arcpy.Mosaic_management("{}".format(Bin2;Bin3),"{}".format(Bin1),"LAST","FIRST","0", "", "NONE", "", "")
code
Parsing error SyntaxError: invalid syntax (line 39) @PolyGeo