Homing Fiducial Pipeline (Video Guide)
If you receive the error message FIDUCIAL-HOME no matches found
when homing your LumenPnP, you likely need to adjust your homing vision pipeline. Follow the steps below for a guide on the iterative approach.
Open the Pipeline
-
Click on the "Position Camera over location" icon button show below. This will move the top camera to the location where your datum board is mounted.
-
Verify that your top camera is positioned exactly over the homing fiducial.
-
Adjust the exposure of your camera image as described in the Homing Fiducial Section.
-
Choose
- Default Machine Fiducial Locator -
from the pipeline list.
Edit the pipeline
This window allows you to modify the vision pipeline for detecting the homing fiducial. Detection is now based on circular symmetry, replacing the older threshold-based circle detection method. Both methods are included here for reference, but we strongly recommend using circular symmetry.
Circular symmetry method
Check your pipeline version
If your vision pipeline does not match the image below, you are using the older method. Update your pipeline by following these steps.
-
Click the "Copy" button in the code block below to save the vision pipeline to your clipboard.
<cv-pipeline> <stages> <cv-stage class="org.openpnp.vision.pipeline.stages.ImageCapture" name="image" enabled="true" default-light="true" settle-first="true" count="1"/> <cv-stage class="org.openpnp.vision.pipeline.stages.MaskCircle" name="mask" enabled="true" diameter="500" property-name="MaskCircle"/> <cv-stage class="org.openpnp.vision.pipeline.stages.DetectCircularSymmetry" name="cir" enabled="true" min-diameter="10" max-diameter="150" max-distance="250" search-width="0" search-height="0" max-target-count="1" min-symmetry="1.2" corr-symmetry="0.0" property-name="" outer-margin="0.2" inner-margin="0.4" sub-sampling="8" super-sampling="1" diagnostics="true" heat-map="true"/> <cv-stage class="org.openpnp.vision.pipeline.stages.ConvertModelToKeyPoints" name="results" enabled="true" model-stage-name="cir"/> </stages> </cv-pipeline>
-
Click the
Clipboard
icon in the vision pipeline window to insert the new pipeline into OpenPnP.
-
Check the output of the
mask
stage. This stage blacks out unnecessary parts of the image to reduce false detections. This reduces the chance that the pipeline will find a different circle in the image and detect it as the homing fiducial. Click on this stage to view and adjust itsdiameter
settings. -
Check the output of the
cir
stage of the pipeline. This stage looks for circular symmetry in the image, and outputs a colored heatmap showing where it thinks the center of circular symmetry is. The goal is to have this stage put the brightest, most yellow point of the heatmap in the center of the homing fiducial. Click on this stage to view its settings.- If OpenPnP detects circular symmetry, you will see a line similar to:
Circle [x=639.5, y=361.5, diameter=78.0, score=133.06040353848752]
in the field in the bottom right of the window. This means OpenPnP found circular symmetry, and it tells you about the circle that it found.
- If no circles are detected, adjust the max diameter circle so that it can find larger ones. Increasing the value for
maxDiameter
will tell the stage to accept circles of a larger diameter.
- If OpenPnP detects circular symmetry, you will see a line similar to:
Legacy - Circle Deteection Method (Outdated)
If your pipeline looks like this, we recommend you switch to the circle symmetry method.
-
The main view will show a detected circle if OpenPnP has identified the homing fiducial.
- If multiple circles are detected, or one detected circle is not correctly drawn around the homing fiducial, refine the filtering until the real homing fiducial is properly detected.
- If no circle appears, we need to adjust the detection setting to make the real homing fiducial easier to identify.
- If the image looks like the reference image, your pipeline is properly tuned.
Adjust Pipeline
-
Adjust the
threshold
parameter as necessary until the image is precise.- If the image is too dark, Increase the
threshold
setting. - If the image is too bright, decrease the
threshold
setting.
- If the image is too dark, Increase the
-
Select the
DrawCircles
stage and verify the fiducial has been correctly identified.
-
Adjust the
param2
parameter as necessary until the correct number of circles are identified.- If no circles are detected, lower the
param2
setting. - If too many circles are detected, raise the
param2
setting.
- If no circles are detected, lower the
Review Pipeline Output
-
Once the fiducial is correctly detected, close the pipeline editor.
-
Attempt to
home
the LumenPnP to see if it can identify the homing fiducial.
-
If you receive the same
FIDUCIAL-HOME no matches found
error, you'll need to keep tuning your pipeline. Go back to checking the debug results.