Python scripting

Questions related to Python API in Metashape Professional

Where to find general Python scripts for Metashape (PhotoScan) Professional
Python scripts for Agisoft Metashape Professional 1.5+ (and PhotoScan Professional 1.3, 1.4) are available in GitHub repository:  Python scripts for Met...
Mon, 3 Oct, 2022 at 11:57 AM
How to download script from GitHub?
This article discribes the workflow of downloading a script from Agisoft GitHub page. The script from the article Script with general processing workflow i...
Wed, 14 Feb, 2024 at 4:04 PM
How to run the script in headless mode from the command-line
To run the script from the command line without using Agisoft Metashape Professional GUI you need to use "-r" argument, like in the examples below...
Thu, 10 Feb, 2022 at 12:42 PM
How to run Python script automatically on Metashape Professional start
In order to execute the script automatically when Agisoft Metashape Professional instance is run you need to place Python script to the following folder: ...
Thu, 10 Feb, 2022 at 12:55 PM
How to install external Python module to Metashape Professional package
To install an external Python module to the package provided with Agisoft Metashape Professional it is necessary to perform the following single-line comman...
Wed, 11 Jan, 2023 at 5:29 PM
How to install Metashape stand-alone Python module
The stand-alone Metashape Python module allows to integrate Metashape functionality to the custom scripts without a need of full application installation. ...
Mon, 4 Mar, 2024 at 5:35 PM
How to calculate estimated Exterior Orientation parameters for the cameras using Python
The example that shows how to calculate the exterior orientation parameters (location and orientation angles) for the aligned camera in the chunk is availab...
Mon, 3 Oct, 2022 at 11:58 AM
How to select fixed percent of the points (Gradual Selection) using Python
The following example shows how to use Python API for selection of the sparse cloud points similar to Gradual Selection option in GUI.  The example show...
Thu, 10 Feb, 2022 at 1:21 PM
Script with general processing workflow
Processing of aerial images with Metashape Professional includes the following main steps: Add Photos Align Photos Build Point Cloud Build DEM Build O...
Wed, 11 Jan, 2023 at 5:54 PM
How to make Python interpreter to use Metashape module
PyCharm makes it possible to use the virtualenv tool to create a project-specific isolated virtual environment. The main purpose of such virtual environment...
Mon, 2 Oct, 2023 at 11:50 AM