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

Batched Kalman Filters #450

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft

Batched Kalman Filters #450

wants to merge 3 commits into from

Conversation

AlexAndorra
Copy link
Contributor

Add batch dimension feature to Kalman filters, to enable fitting multiple time series at the same time

@AlexAndorra AlexAndorra added the enhancements New feature or request label Apr 4, 2025
@AlexAndorra AlexAndorra self-assigned this Apr 4, 2025
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@AlexAndorra AlexAndorra removed the request for review from jessegrabowski April 8, 2025 16:36
@AlexAndorra
Copy link
Contributor Author

Pushed latest progress: working with Filter, not yet with Smoother

@twiecki twiecki requested a review from Copilot April 11, 2025 03:39
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Comments suppressed due to low confidence (1)

conda-envs/environment-test.yml:20

  • [nitpick] The pip dependency list appears to have a potentially misformatted entry ('- -e .'); please verify the correct YAML structure to ensure dependencies are installed as intended.
- -e .

Comment on lines +78 to +85
assert 0
# outputs = filter_func(*inputs)

for output_idx, name in enumerate(output_names):
expected_output = get_expected_shape(name, p, m, r, n)
assert (
outputs[output_idx].shape == expected_output
), f"Shape of {name} does not match expected"
expected_shape = get_expected_shape(name, p, m, r, n, batch_size)
# assert outputs[output_idx].shape == expected_shape, (
# f"Shape of {name} does not match expected"
# )
Copy link
Preview

Copilot AI Apr 11, 2025

Choose a reason for hiding this comment

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

A hard-coded 'assert 0' is present in the test_output_shapes_one_state_one_observed function, which forces the test to fail. Please remove this debugging placeholder to allow the test to run normally.

Copilot is powered by AI, so mistakes are possible. Review output carefully before use.

mus_, covs_ = mus.type(), covs.type()
print(f"mus_.type.shape: {mus_.type.shape}, covs_.type.shape: {covs_.type.shape}")
Copy link
Preview

Copilot AI Apr 11, 2025

Choose a reason for hiding this comment

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

Debug print statements remain in the rv_op function; consider removing them before merging to clean up output in production.

Suggested change
print(f"mus_.type.shape: {mus_.type.shape}, covs_.type.shape: {covs_.type.shape}")
# Debugging information removed or replaced with logging if necessary

Copilot is powered by AI, so mistakes are possible. Review output carefully before use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancements New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant