Skip to main content
Version: dev-latest

Choosing and Constructing Calibration Targets

MetriCal depends on printed calibration targets (also referred to as fiducials) of a known size in order to calculate things like camera intrinsics and relative transforms between multiple sensors. Using these targets, MetriCal is capable of calibrating many different sensor modalities and arrangements. However, each different calibration problem has unique considerations and requirements when it comes to the amount, type, and positioning of targets. For simple problems like single camera calibration, you can often get away with just one target. More complex and multimodal sensor arrays often require a bit more thought when choosing targets, though.

This guide will walk you through the process of choosing and constructing a set of targets designed to solve your specific calibration problem.

Step 1 - Develop a Rough Data Capture Plan

Before you can figure out what targets you need, you'll need to understand roughly how and where the actual calibration process will take place. Some considerations to take into account:

  • What sensor modalities are you calibrating? Different modalities have different requirements. For example, lidar requires special retroreflective targets, IMUs require excitation of the sensor, cameras need visible targets to be sized properly relative to their FOV, etc.
  • All modalities supported by MetriCal require some amount of motion. Will you be moving the sensor array (ego-motion), or the targets (object-motion)? In multi-target scenarios, the targets need to stay rigidly constrained to one another, which can make object-motion tricky (but not impossible).
  • Where will your calibration take place? Do you have enough room to perform your motion sequence while keeping targets within the FOV / focus range / minimum detection distance of all sensors?
  • How will you mount your targets? Will they be permanent fixtures, or will they require occasional setup and teardown?
  • How will you mount your sensors? If you plan on using ego-motion while the sensors are mounted to a heavy chassis, how will you move them?
  • If designing a calibration process for a production line setting, how will you ensure repeatability?

Note that we generally recommend capturing data all at once, but MetriCal does support processing calibration data in multiple stages for complex problems. For some more practical examples of data capture, take a look ahead at the data capture section of this tutorial.

We've found that nailing down a good data capture process is both the most difficult and most important component of getting consistent calibration results. It can be an iterative process. If you go through these documents and still feel unsure about the best protocols for your specific calibration problem, please reach out to us at support@tangramvision.com. We've worked with customers across many different industries and stages of life so, whatever your situation, we'll be able to help.

Step 2 - Decide on the Amount and Layout of Targets

If you are only calibrating a single camera, you probably only need one target. For calculating extrinsics between multiple sensors, though, there are many cases when you'll need multiple targets.

In general, you'll always want at least two sensors to be simultaneously capturing relevant data. For example, if you are interested in finding the extrinsics between a camera and an IMU, you'll want multiple targets so that the camera will always have one in its field of view regardless of the orientation of the device (so that you can excite all axes of the IMU while the camera can still observe at least one target). If you are finding the extrinsics between two cameras facing different directions, you'll need to be sure that each camera always has at least one target in its field of view.

Similarly, you'll need to ensure that the targets are placed such that there are times when multiple targets can be observed by the same sensor. This is because MetriCal calculates and optimizes the relative transforms between targets (much like it does with sensors).

Up to an extent, this all means that having more targets will make it easier to get good results, though there's a point of diminishing returns (and the expense of making more targets). MetriCal also requires that all of the markers on your targets have unique IDs, so there comes a point where having too many targets will cause you to run out of available IDs (see the object space docs for more info).

Finally, when using multiple targets, their relative transforms need to remain constant for the duration of the calibration sequence. So you'll need to consider how you can practically mount each target in a multi-target scenario.

Step 3 - Download and Run the Target Selection Wizard

When using MetriCal, we generally recommend choosing from the premade targets in our target repository. Though it is possible to design your own targets with other tools, or repurpose targets that you may have used with other calibration software, we have found that can often lead to subtle bugs. In fact, issues with the object space file (the file that describes all of your targets and their various properties) as well as target selection in general are some of the most common problems encountered by new and experienced users of MetriCal alike. Using these prebuilt targets helps prevent many of these types of issues.

All targets in the premade target repository come with the object space file that was used to generate them, so they're guaranteed to be accurate. Additionally, the target repository includes a target selection wizard that helps you automatically select targets that are valid in combination with one another. Once you've selected all the targets through the wizard, it will automatically combine their object space files into a single file that is compatible with MetriCal.

To use the target selection wizard, you'll need a system with Python 3 installed. Download the target repository, run python3 target_selection_wizard.py <OUTPUT_DIR>, and follow the onscreen instructions. When complete, the wizard will output PDFs of all chosen targets to the chosen output directory, as well as an object space json file that can be used directly with MetriCal.

We recommend having this target selection wizard running as you follow the rest of this tutorial, as it will show you all of the valid premade options available to you at each step.

Step 4 - Generate PDFs for Each Target

Again, it's highly recommended that you use the target selection wizard for this step. If you're opting not to, you can look at the object space docs for some info on both the formats we support and the types of data you'll need to provide to MetriCal through your object space file. The instructions below are written to mirror the experience of using the wizard, but you'll need to take the same steps if designing your own target as well. For each target, you'll need to do the following:

  1. Decide whether or not the target needs to be detected by lidar — Calibrating lidar requires constructing lidar-specific targets with a circular retroreflector. These targets are detectable by both cameras and lidar, which allows for calibration of extrinsics between those two types of sensors. It is possible to have more than one lidar target, so long as the radius of each retroreflective circle differs by at least 10cm. Also, not all of your targets need to be lidar-compatible — you can mix lidar and non-lidar targets. For example, when calibrating a multi-camera sensor array and a 360-degree FOV lidar, you can often get away with having multiple camera-only targets but only one that's lidar-compatible. If you aren't calibrating a lidar, you don't need any lidar targets.
  2. Choose the largest target size that you can practically use — This is not a hard and fast rule, but generally bigger targets are more advantageous when it comes to calibration quality. They can be seen from farther away, can be seen by more cameras at once at a given distance, can contain more markers and features, etc. Of course, bigger targets are more expensive to make and require more space to install. If you are opting for an object-motion setup, bigger targets can be much more difficult to manipulate manually. Once the target is big enough to exceed the FOV of your camera at the desired capture distance, there is much less advantage to increasing size any further.
  3. Prefer Aprilgrid-style targets over Markerboard — Camera calibration relies on detection of specific markers on each target. These markers are used to both identify the target and to generate features that are used in the optimization process for intrinsics and extrinsics. Markerboard (ChArUco) targets used to be our preferred style of board, but we have since greatly improved the quality of our Aprilgrid detector, and now recommend that instead. Aprilgrid-style boards have the advantage of much higher feature density per marker, which should improve calibration quality. Valid reasons to use Markerboards might include the larger tag ID dictionary (ability to use more targets at once) or to fit into an existing calibration pipeline that you may have developed beforehand that depends on Markerboard-style targets.
  4. Choose marker density based on your cameras — Higher marker density will create more features for the calibration process to use, but risks detection failures at higher distances from the camera or at lower resolutions. In general, the premade "standard" density targets are a sane option if you're unsure what to use. If you plan on using the target very far away from your camera or if your camera is very low resolution, "sparse" may be appropriate. The opposite is true for "dense", though it's better to err on the side of more sparse. It's more important to get any detections at all than it is to optimize for getting as many as possible. You can also determine the marker size of a target (printed in the top left on premade targets) and use trigonometry, your camera FOV, and your sensor resolution to figure out its size in pixels at your farthest anticipated capture distance. You should aim for markers to always appear larger than 20px. MetriCal can detect markers smaller than that in ideal cases, but it becomes easy to run into trouble when dealing with inexact focusing, compression artifacts, and similar issues.
  5. Choose marker ID offsets to prevent overlap — Each of your targets needs to have completely unique marker IDs, otherwise MetriCal will be unable to differentiate between them. The selection wizard handles this for you, but you need to keep this in mind if reusing existing targets or designing your own.

If you have unique constraints and feel that the premade targets are insufficient, please send an email to support@tangramvision.com. We have also designed and implemented custom target detectors for clients in the past, and are able to help with any special requests.

Step 5 - Print and Assemble the Targets

When you finish picking all of your targets, the wizard will dump their corresponding PDFs into the output folder that you selected at the start of the process. From here, you'll need to find a print shop that can print targets of the chosen sizes. For US-based customers, we have had good experiences using uprinting. We generally recommend printing either on foam board (lighter for carrying during object-motion captures) or aluminum (more durable and easier to mount). When sending your targets to a printer, be sure to request that they center the PDFs rather than scaling them at all. Maintaining the exact scale of the final printed markers is very important.

If you printed lidar targets, you'll need to apply retroreflectors to the printed yellow circle on them as a separate step. You can use any retroreflective tape cut into small segments and applied carefully such that the yellow circle is covered as evenly as possible. For our premade lidar targets, we also offer precut, exactly-sized retroreflective stickers that are easier to apply consistently — email us for more details.

Step 6 - Verify Measurements and Construct Your Object Space File

As a last step, we recommend that you measure your target after it is printed, just to verify that it is correctly scaled. All of our premade targets have size info printed in the top left corner. For Aprilgrid targets, we recommend measuring one of the markers and ensuring that it matches up with the marker_length field. For Markerboards, measure one of the black squares and ensure that it matches up with the checker_length.

If you've used the target wizard up to this point, it will already have output an object space json file for you to use with MetriCal, so you're ready to move on to the next tutorial. Otherwise, you'll need to consult the object space docs and make your own object space file based on your measurements before continuing.