APS Excellence in Physics Education Award
November 2019

Education Prize Logo
Science SPORE Prize
November 2011

NSF Logo
The Open Source Physics Project is supported by NSF DUE-0442581.

Unexpected behavior X-axis Only autotracker post and replies

Return to the Unexpected behavior X-axis Only autotracker thread
Login to post to this thread

Unexpected behavior X-axis Only autotracker
Sander Wildeman
2 Posts

Dear tracker community,

I'm trying to get the X-axis Only feature of the autotracker to work to track an edge. However, the detected points still seem to wander off the x-axis when the feature is enabled, even going outside the search area sometimes (see attached screenshot).

I'm using tracker version 6.2 on Mac OS 12.7.5. I checked that the Java version is the bundled one.

Any ideas what might be going wrong or how to resolve this?

Best regards,
Sander

Attached File: Screenshot20241005at12.41.31.png


Replies to Unexpected behavior X-axis Only autotracker

Re: Unexpected behavior X-axis Only autotracker -
Sander Wildeman
2 Posts

A small update. I dug a bit into the OSP/Tracker source code on GitHub to see if I could find a cause for the behavior.

My current hypothesis is that it could have to do with the sub-pixel refinement step in the template matcher (media/core/TemplateMatcher.java). This optimization step seems to assume that the correlation peak is two-dimensional, while this is not the case for an edge (the direction parallel to the edge won't have a well defined (sub-pixel) peak location).

If this suspicion is correct (and this is indeed unintended behavior) a fix might be to make getMatchLocation() aware of the line (x-axis) along which the search is performed and project the (dx,dy) correction on this line.



OSP Projects:
Open Source Physics - EJS Modeling
Tracker
Physlet Physics
Physlet Quantum Physics
STP Book