Skip to content

Shadowfinder 2.0b#26

Open
JackCollins91 wants to merge 8 commits intobellingcat:mainfrom
JackCollins91:Shadowfinder-2.0b
Open

Shadowfinder 2.0b#26
JackCollins91 wants to merge 8 commits intobellingcat:mainfrom
JackCollins91:Shadowfinder-2.0b

Conversation

@JackCollins91
Copy link
Copy Markdown

I have added functionality to allow users to input the details of multiple shadows taken at the same location across timestamps. This should allow users to narrow down the possible locations. I implement multiprocessing across cores for performance. This requires adding multiprocessing modules to the dependencies.

This is accomplished through two new static functions in shadowfinder.py

multi_shadow_find
and
plot_multi_shadows

I refactored the ShadowFinder().plot_shadows function to separate out some of the plotting functionality into ShadowFinder()._plot_shadows. This enables code re-use in plot_shadows.

unit tests and example

  • unit test tests/test_shadowfinder.py::test_multi_shadow_find passing
  • examples/example_multi_shadow_find.py behaving as expected

The example script is used to visualize that the results make logical sense. I show that this can be applied to three shadows, although in principle, it should scale to any number.

Example: three shadows across different times with local time formats.

example_multi_shadow_find_figure

JackCollins1991 and others added 6 commits November 30, 2024 12:42
- Added multi_shadow_find
- Added normalize_product function to normalize the product of location_likelihoods.
- Added plot_multi_shadows function to plot the output of multi_shadow_find.
- Added unit test for multi_shadow_find in test_shadowfinder.py.
- Ensured that the unit test checks the type, shape, and values of the normalized output.
- Code untested. tests may not pass.
@JackCollins91 JackCollins91 mentioned this pull request Dec 7, 2024
@JackCollins91
Copy link
Copy Markdown
Author

@GalenReich this PR is a bit stale, but I could revive it if there's still interest in this requirement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants