Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding an example showing an explicit MHT application using MFA components #954

Merged
merged 9 commits into from
Jun 19, 2024

Conversation

A-acuto
Copy link
Contributor

@A-acuto A-acuto commented Feb 7, 2024

This PR adds an example of a Multi-Hypothesis tracking using the Multi-frame assignment components.
This example was supposed to rely more on Stone Soup components (e.g., GaussianMixtureInitiator and MultiTargetTracker), however the current implementation of such components is not aligned with the MFA components making complex to deal with it (e.g. #896).

This example shows how to set up this type of simulations in a more general way than the example present in the documentation.

@A-acuto A-acuto requested a review from a team as a code owner February 7, 2024 17:12
@A-acuto A-acuto requested review from orosoman-dstl and csherman-dstl and removed request for a team February 7, 2024 17:12
Copy link
Contributor

@orosoman-dstl orosoman-dstl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks great - it's mostly fixes to the grammar/wording from me.

docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved

tracks.add(track)

plotter.plot_tracks(tracks, [0, 2], track_label="Tracks", line=dict(color="Green"))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at this plot, one track is distracted by the clutter and flies off in a straight line towards the bottom left of the graph. Is this something you want to address, either by commenting on the algorithm's performance or by changing parameters to obtain a better result?

docs/examples/mht_example.py Outdated Show resolved Hide resolved
docs/examples/mht_example.py Outdated Show resolved Hide resolved
# We have prepared all the general parameters for the simulation,
# including the clutter spatial density. In this example we set
# the birth rate and the death probability as zero, using only the knowledge of the
# prior states to generate the tracks so the number of targets is fixed (3 in this case).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Am I right in thinking that MFA (or this implementation) only works with fixed number of tracks?

@A-acuto
Copy link
Contributor Author

A-acuto commented Feb 16, 2024

Hi @orosoman-dstl and @sdhiscocks : I have applied the suggested changes to the text and references.
Now all tracks follows the ground-truths better and there is no more track drifting.

Regarding @sdhiscocks question about the number of tracks: I tried using the GaussianMixtureInitiator with unknown number of tracks (e.g. using the MultiTargetGroundTruthSimulator) but I was not able to make it work properly with the tracking loop needed for the MFA data associator. Hence my approach of fixing the number of targets and start the tracks in this way.

Happy to discuss a more general solution (if possible with the current setup).

@sdhiscocks
Copy link
Member

Regarding @sdhiscocks question about the number of tracks: I tried using the GaussianMixtureInitiator with unknown number of tracks (e.g. using the MultiTargetGroundTruthSimulator) but I was not able to make it work properly with the tracking loop needed for the MFA data associator. Hence my approach of fixing the number of targets and start the tracks in this way.

To be honest, I wasn't sure if there was a limitation in the actual algorithm itself that means it assumes fixed number of targets, or limitation of the implementation. I've found when trying to use with varying targets, you can get an RuntimeError due to "Infeasible primal problem", which I suspected could be related to varying the number of tracks.

@mharris-dstl mharris-dstl linked an issue Apr 30, 2024 that may be closed by this pull request
@sdhiscocks sdhiscocks merged commit 5bb6c5c into dstl:main Jun 19, 2024
4 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Any ideas on TO-MHT implementation?
4 participants