Thanks Alexey,
I have set up the project file so that the photos are pre-aligned and all the ground control is identified and the coordinates are loaded, then I run the following script:
import PhotoScan, os
path = PhotoScan.app.getExistingDirectory("Please choose the folder with .psz files:")
print("Script started")
doc = PhotoScan.app.document
doc.clear()
project_list = os.listdir(path)
for project_name in project_list:
if ".PSX" in project_name.upper():
doc.open(path + "/" + project_name)
chunk = doc.chunks[0]
#Optimize Cameras
chunk.optimizeCameras(fit_f=True, fit_cxcy=True, fit_b1=True, fit_b2=True, fit_k1k2k3=True, fit_p1p2=True, fit_k4=False, fit_p3=False, fit_p4=False)
#Build dense cloud
chunk.buildDenseCloud(quality=PhotoScan.HighQuality, filter=PhotoScan.AggressiveFiltering, keep_depth=False, reuse_depth=False)
#Export dense cloud as a .laz
cloud_name=os.path.splitext(project_name)[0]
chunk.exportPoints(path + "/" + cloud_name +".laz", binary=True, precision=6, normals=True, colors=True, format='laz', projection=PhotoScan.CoordinateSystem('EPSG::26911'))
doc.save()
print("Processed project: " + project_name)
else:
continue
print("Script finished.")
So it should give the same result - or is the stochastic element in the optimization or cloud reconstruction?