0% found this document useful (0 votes)
59 views14 pages

Metashape Aerial Imagery Guide

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
59 views14 pages

Metashape Aerial Imagery Guide

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Last Updated: November 2021 (Metashape 1.7.

3)

Metashape Image Processing for


Digital Aerial Imagery

Introduction
Metashape is a tool for orthocorrecting imagery taken with a non-metric camera and can align and
calibrate the camera with minimal input from the user. The program can also process scanned historical
imagery and terrestrial imagery. In this exercise, you will learn the basics of Agisoft Metashape as you
produce an orthomosaic and a 3-D point cloud. The exercise data consists of six aerial images taken with
a Canon DSLR camera while flying over a portion of the Tongass National Forest in Alaska with a fixed-
wing airplane.
As you work through this exercise, please refer to the Metashape Help Documentation for additional
information about each of the steps. The help documentation can be found by going to the main menu
in Metashape and selecting Help and then Contents.

Objective
• Become familiar with the user interface and features found within Metashape.
• Learn how to create an orthomosaic and 3-D point cloud with Metashape.

Prerequisites
• Download and unzip exercise data: Metashape_digital_aerial.zip.
• Install and activate Metashape (please see Metashape Installation Guide for details).

Table of Contents
Part 1: Getting Started ..................................................................................................................... 2
Part 2: Define Projection and Place Markers ................................................................................... 5
Part 3: Optimize the Camera ........................................................................................................... 8
Part 4: Create Products .................................................................................................................... 9
Appendix A: Marker Locations ....................................................................................................... 13

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 1


Part 1: Getting Started
A. Adjusting Preferences
Before we start processing the images, let’s make sure that Metashape is set up correctly. If you
have a powerful graphics card (GPU), we’ll want to make sure it is turned on. We also need to make
sure that you are using the same theme as was used to create the graphics in this exercise.
1. Launch Metashape from the Start menu (Start, All Programs, Agisoft, and Agisoft Metashape
Professional).
2. Open up Metashape Preferences by clicking Tools and Preferences.
3. With the General tab selected, find the dropdown for Theme and change it to Classic (see
following note).

NOTE: We’ll be using the Classic theme for these exercises to ensure that we’re all using the same
interface. However, feel free to check out the Dark and Light themes, but just remember that some of the
tool locations and button symbols are different from what are shown in this exercise.

4. Click GPU tab. If you only see your integrated GPU device listed (usually Intel…) then place a
checkmark next to it and place a checkmark at the bottom next to Use CPU when…. However,
if multiple GPUs are listed, uncheck your integrated (Intel) GPU and place checkmarks next to
only your most powerful GPUs, such as NVIDIA Quadro or other series. Also, in this case, leave
the Use CPU when… box unchecked (see following figure for example).

5. If needed, restart Metashape to switch to the Classic theme.

B. Add the imagery


1. Add the project images by going to the main menu in Metashape and selecting Workflow and
then Add Photos.
i. Navigate to the 01_imagery folder in your exercise data and select the six images in the
list (see following figure) and then click Open. The photos should now be added to both
the Photos pane and the Workspace pane (see following note).

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 2


NOTE: Metashape uses multiple panes for displaying different types of information. By default, some
panes share the same screen space and can be displayed by clicking on the tabs above or below the
pane. For example, the Workspace and Reference panes share the same screen space. Also, you can turn
the panes on and off by going to View and then Workspace. The panes can also be resized and
rearranged.

2. View one of the images by double clicking on it in either in the Photos pane or the Workspace
pane (click on the arrow next to Chunk 1 and then Cameras to display the list of images).
i. Navigate around the image by using your mouse (scroll wheel for zooming and left button
for panning).
ii. To get back to the 3D model view, click on the Model tab at the top of the main viewer or
close the image tab by clicking on the “X” in the image tab.
3. Next, take a look at the camera information, which is automatically imported from the
metadata (EXIF data) embedded within each of the images. In the main menu, click on Tools
and then Camera Calibration.
i. Since all six images were taken with the same camera, they should all be in the same
camera group (listed as “unknown” on the left side) and will later be calibrated together.
ii. The metadata for the original TIFFs didn’t copy over when converted to JPEGs. Go ahead
and enter in the following camera information:
(a) Camera type: Frame
(b) Pixel size: 0.006549
(c) Focal length: 50
iii. After verifying that the information is correct, go ahead and click OK.

C. Align the images


In this step, the software will align the images by matching features found in overlapping regions of
the images. The end result is the initial alignment of the images, as well as a sparse point cloud of
the points that were matched. This alignment step is oftentimes called Structure from Motion (SfM).
1. In the main menu, click on Workflow and then Align Photos. Use the following settings (see
following note):
i. Accuracy: High
ii. Pair preselection: Generic
iii. Reference preselection: unchecked (you can turn this on if the images have GPS
coordinates associated with them)
iv. (Advanced section) Key point limit: 40,000

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 3


v. (Advanced section) Tie point limit: 4,000
vi. (Advanced section) Leave Guided image matching and Adaptive camera... unchecked.
2. Click OK to run alignment. This may take a minute or so to process (see following note).

NOTE: The Image Alignment step is very computationally intensive and for larger datasets may take
several hours to complete. Time will vary depending upon computer processing power, number of
images, and image size. Processing time can be slightly reduced if GPS data is available for the images.
The GPS data can either be imported by going to the Reference pane and clicking on the Import
Reference button or will automatically appear in the Reference pane if the images are geotagged (very
common with UAS imagery).

3. Once image alignment finishes, you will see six blue rectangles appear in the main viewer,
which represent the camera positions. If you do not see the blue rectangles, click on the Show
Cameras button in the main toolbar. A sparse point cloud with the points used to align the
images should also be visible in the viewer (see following figure and note).

NOTE: In the Photos pane, a green checkmark will appear above images that are successfully aligned. If
an image(s) doesn’t align properly, right click on it and select Align Selected Cameras. If Metashape still
fails to align the image(s), try realigning all of the images again using different settings (quality, key
point/tie point limits). Another option is to manually add tie points (markers) between images that
aren’t aligning. However, Metashape will struggle to align images that have insufficient image overlap.

4. In the main toolbar, make sure the Navigation tool is selected (see following figure).

5. Move around the model by using your mouse (scroll wheel to zoom in and out, left button for
rotating, and holding down scroll wheel for panning). Also, to center the viewer on a specific

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 4


spot on the model, double click a point. Also, if you wish to hide items that are in the viewer
(e.g., the big rotation ball), click on Model in the main menu and then Show/Hide Items.

Part 2: Define Projection and Place Markers


In this second part, we will define the projection for the project and then use control points, or markers
as Metashape calls them, to geospatially position and scale the model. Ground coordinates for markers
generally come from another reference image or by collecting the information in the field with a GPS
unit. The latter method generally produces the most accurate results, but is also the more expensive
and labor intensive of the two. The markers provided to you in this exercise were created using the
reference-image method. A minimum of three markers are needed for georeferencing the model.
However, for best results, it is recommended to distribute between 10 to 15 markers throughout the
model. We’ll only be placing 8 markers in this exercise.
Metashape recently added a global reference image and DEM to the Ortho tab. To enable these
reference datasets, click on the Ortho tab in the main viewer and click Show Basemap button in the
main toolbar. This allows you to gather marker coordinates within Metashape. Before, marker
coordinates had to be obtained outside of Metashape by using tools such as Google Earth or ArcMap.
However, for this exercise, we’ll provide you with the coordinates and placement of the markers.

A. Define the projection


1. Click on the Reference tab (located at bottom left of screen) to activate the reference pane.
Click on the Settings button (see following figure).

i. For the coordinate system, select North American Datum 1983 / UTM zone 8N
(EPSG:26908). Filter using the EPSG code (26908) to quickly find it.
ii. Change the Marker accuracy located under Measurement Accuracy to 0.1. Leave the
default values for the other fields and click OK (see following note).

NOTE: Since the markers for this exercise were created from reference imagery, we need to reduce the
accuracy accordingly. This allows the software to be more flexible with the solution. If you are working
with your own data, you’ll want to adjust this setting based on the accuracy of your markers. Keep in
mind that your outputs will only be as accurate as your reference data.

B. Import the markers


1. Click on the Import button (see following figure), which is at the top of the reference pane.

i. Navigate to the 02_reference folder and select markers_XYZ.csv and then click Open.
(a) Change the coordinate system to NAD83 / UTM zone 8N.
(b) Change the delimiter to Comma, if needed.
(c) Set the Start import at row field to 2 to avoid importing the column headers.
(d) The columns should already be in the correct order (1, 2, 3, and 4).
(e) Click OK to import the markers.

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 5


ii. A message will open saying that it can’t find a match for ‘1’ entry. Select Yes to All (see
following note). The coordinates should now be displayed under Markers.

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 6


NOTE: The import dialog window is also used to import the camera center (GPS) coordinates that can be
used in the initial alignment step. By default, Metashape assumes that the imported coordinates are
camera centers, so it tries to match them with the image names. By selecting Yes to All in the previous
step, you are telling Metashape that these coordinates are to be used as markers instead of camera
coordinates. After doing this, you should see the eight newly added markers in the Reference pane.

C. Place markers on photos


We need to now specify where these markers are located on each of the photos. Metashape will
help out after placing a few of them. See Appendix A to see where to place each of the markers.
Try to place the markers as accurately as possible.
1. Using the first graphic in Appendix A, determine which images Marker 1 falls on (answer:
IMG_0332 and IMG_0331). In the Photos pane, double click on IMG_0332.tif to display it in
the main viewer. Using the graphics in Appendix B as reference, navigate to Marker 1.
2. Right click on the image where Marker 1 is to be placed and select Place Marker and then 1.
Marker 1 should now be visible on the image with a green flag (see following figure). If the
green flag isn’t visible, click on the Show Markers button in the main toolbar.

3. In the Photos pane, double click on the next image (IMG_0331.tif) that Marker 1 fall on to
open it in main viewer.
4. Zoom and pan around the image to find the location of Marker 1. You’ll notice that a red and
white line appears on the image to show you approximately where Marker 1 is located (see
following figure).

5. Once you find the location, right click and select Place Marker and 1 (see following note).

NOTE: If you accidentally place the marker in the wrong location or need to adjust its position, you can
click on it and drag it to the correct location. There are also additional options if you right click on it.

6. Repeat steps 1 through 5, but now for the remaining seven markers (see following note).

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 7


NOTE: After placing three markers, Metashape is able to estimate the placement of the remaining
markers. To do this, click on the Update button (see following figure) in the reference pane.

After a few seconds, a grey symbol will appear above each image in the Photos pane (see following
figure) showing which of the images have estimated markers. You can now right click on each of the
remaining markers in the Reference pane and select Filter Photos by Marker. The images that intersect
the selected marker will show up in the Photos pane. Double click one of these images to navigate to the
estimated marker and adjust the marker’s position to finalize it (it should turn to a green flag).

7. Save your project file by clicking on File and then Save.

Part 3: Optimize the Camera


Now that the images have been aligned and the markers have been placed, we need to optimize the
camera alignment. The goal of this step is to improve the accuracy of the interior and exterior
parameters of the camera, thus correcting for lens and sensor distortions. This is done by iteratively
removing tie points that have higher standard errors and then re-optimizing the cameras. The following
is a simplified approach for optimizing the cameras. The BLM has developed a more complete
optimization workflow, which can be found in your exercise material (BLM_optimize_workflow.pdf).

A. Optimize the cameras


1. In the main menu, click on Tools and then Optimize Cameras or click on the tool in the
Reference pane (see following figure).

2. In the Optimize Camera Alignment window, place a checkmark next to all items except for
k4, b1, and b2 (see following figure) and then click OK. Metashape quickly runs aerial
triangulation and optimizes the camera parameters to better fit the reference data.

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 8


B. Delete points and rerun optimization
Some of the points found in the sparse point cloud may have been incorrectly matched. By using the
gradual selection tool, we can select the points that are more likely to contain larger errors and
remove them from the model. This can improve the accuracy of the subsequent optimization steps,
which will also improve the accuracy of the end products.
1. Make sure that the model tab is selected and open the Gradual Selection tool by clicking on
Model in the main menu and then Gradual Selection.
i. Select Reprojection error and then adjust the slider to around 0.3. The points that are
above the threshold will become selected and turn red in the viewer. The number of total
points and selected points can be seen in the bottom-left corner of the main viewer.
ii. Click OK to finalize the selection.
iii. Delete the selected points by clicking the Delete button in the main toolbar (see
following figure) or by hitting the delete button on your keyboard.

2. Click on the Optimize Camera Alignment tool again and rerun it using the same parameters
used previously.

Part 4: Create Products


Now that we have aligned the images and optimized the sensor, we are now ready to create a dense
point cloud and orthomosaic. In this section, we will first create a dense point cloud. We will then create
a mesh from the dense point cloud and use it as the surface model for the orthomosaic.

A. Create and export a dense point cloud


1. In the main menu, select Workflow and then Build Dense Cloud.
i. Change the quality to Medium and depth filtering (in advanced) to Mild.
ii. Click OK. The process may take a few minutes to complete, depending on the processing
power of your computer (see following note).

NOTE: The quality level that you select depends on the imagery that you are working with and what you
are hoping to do with the point cloud. Ultra-high will attempt to match every pixel, but may result in a lot
more processing time and the product may end up having holes where matches were unsuccessful. Each
level that you drop down, Metashape downscales the image by a factor of 4. Usually it is a good idea to
start with medium and then bump it up to a higher level if more detail is desired.

2. View the dense point cloud by clicking on the Dense Cloud button (see following figures) in
the model toolbar.

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 9


3. Go ahead and explore the point cloud by using your mouse to zoom, pan, and rotate the point
cloud.
4. Optionally, if you want to view or further process the point cloud using another software
application (e.g., Fusion, ERDAS Imagine, or ArcMap), you can export the point cloud by
clicking on File, Export, and then selecting Export Points.

NOTE: If you don’t need a dense point cloud or orthomosaic for the entire area, you can use the region
tools to specify the output boundary (see following figure). This can be very helpful for when you need to
create products for specific areas within the set of images, or even for quickly testing out the Metashape
parameters. The main tools for adjusting the boundary are the Resize, Move, and Rotate Region tools
found in the model toolbar.

B. Build a mesh
1. In the main menu, click on Workflow and then select Build Mesh.
2. Use the following settings:
i. Source data: Dense cloud
ii. Surface type: Height field
iii. Quality: Medium
iv. Face count: Medium
v. Select OK to create the mesh.

NOTE: Either a mesh or digital elevation model (DEM) is needed to create an orthomosaic. Metashape
offers multiple approaches for doing this, as listed here: (1) a DEM (TIFF format) can be imported by
going to File, Import, and then clicking on Import DEM; (2) a mesh can quickly be generated from the
sparse point cloud by selecting Sparse Cloud instead of Dense Cloud in the Build Mesh workflow; (3) a
detailed mesh can be created from the dense point cloud, as explained in the previous step. Which
method you select depends on the level of accuracy desired and the availability of an accurate DEM.

3. To display the mesh, click on one of the three mesh buttons in the model toolbar (see
following figure).

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 10


4. We will now smooth the mesh by clicking on Tools in the main menu and selecting Mesh and
then Smooth Mesh.
i. Set the Strength to 3 and select OK (see following note).

NOTE: By smoothing the mesh, we are removing the individual tree crowns and making a pseudo-terrain
model. This type of mesh works best for creating a traditional orthomosaic. It is possible to skip this
smoothing step and go directly to creating the orthomosaic. This results in the creation of a “True Ortho”
that attempts to remove building and tree lean. This approach can be useful if your imagery has a lot of
overlap (>80%), but can otherwise introduce image smearing and other unwanted image artifacts.

C. Create and export orthomosaic


1. In the main menu, click on Workflow and then select Build Orthomosaic.
2. Select the following options:
i. Type: Geographic (UTM zone 8N)
ii. Surface: Mesh
iii. Blending mode: Mosaic
iv. Pixel size: approximately 0.17 for both X and Y (the software automatically calculates the
optimal pixel size)
v. Select OK to create the orthomosaic
3. To view the newly created orthomosaic, go to the Workspace pane and double click on
Orthomosaic. If you don’t see it, be sure to expand Chunk 1 in the Workspace pane.
4. Go ahead and explore the orthomosaic by zooming in and panning around the image with
your mouse scroll wheel.
5. Optionally, if you want to use the orthomosaic in another software application, you can
export it by right clicking Orthomosaic in the Workspace pane and selecting Export
Orthomosaic and then select Export JPEG/TIFF/PNG… (see following note).

NOTE: There are a couple of options in the export window that are worth mentioning. First, if you are
working with a large dataset, you can split the mosaic into tiles by checking the Split in blocks box and
specifying a tile size. Another useful feature is the ability to specify your output region by checking the
Setup boundaries box and entering in the bounding coordinates.

D. Generate project report


Before we finish this exercise, let’s create a project report to document the project setup and
outputs. Within the project report, you will find information about the camera calibration, point
clouds, markers, aerial triangulation results, and the final ortho.
1. In the main menu, click on File, Export and then Generate Report.
i. Give the report a title and a description.

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 11


ii. Select Top XY for the projection and hit OK. This is the view of the model that is displayed
on the front cover of the report. Only Top XY and Current View are really applicable when
working with orthomosaics.
iii. Navigate to an output directory, give the file a name, and click on Save.
2. Locate and open your newly created PDF report.
3. Browse through the project report to become familiar with the contents.
4. Go ahead and save your Metashape project file one last time.
5. Optionally, you can explore a few other features found in Metashape such as creating and
exporting a DEM (Workflow and then Build DEM), exporting individual orthophotos (right
click Orthomosaic and select Export Orthophotos), exporting an orthomosaic as a Google
KMZ file (right click Orthomosaic and select Export Orthomosaic and then Export Google
KMZ), and creating a 3D PDF of the model (click on File and select Export, Export Model and
then select Adobe PDF as the file type).

Conclusion: In this exercise, we learned how to use Metashape to orthocorrect aerial imagery
and create products such as an orthomosaic and dense point cloud. Metashape is a great tool
for working with imagery captured with a non-metric sensor since it is able to calibrate the
camera and align the images with minimal input from the user. Metashape can also be used for
processing scanned historical photographs and ground-based imagery. Additional resources,
including a few tutorials and a very helpful user forum, can be found at [Link].

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 12


Appendix A: Marker Locations
Markers (i.e., control points) are crucial for geospatially positioning and scaling the imagery. Marker
coordinates are generally obtained with a GPS unit in the field or by using a reference image (as was
done for this exercise). Each marker needs to be located and added to each image it intercepts. For
example, marker 1 needs to be added to images IMG_0332 and IMG_0331 since it intercepts both of
these images. The graphic below shows the marker locations and the image footprints.

Refer to the following zoomed-in images to know where to place the markers. Since the scale and
placement depends upon these markers, it is important to place them as accurately as possible.

Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 13


Geospatial Technology and Applications Center | Metashape: Digital Aerial Imagery | 14

You might also like