-
Notifications
You must be signed in to change notification settings - Fork 159
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
add Base.copy(::ParticleFilterState) #509
Conversation
Looks great! It strikes me that we might also want to implement |
@ztangent For equality, what do you think between the following possible semantics? For checking equality w.r.t. particle weights:
For dealing with The benefit of doing 1-A is that it would make it easier to do things like dictionary lookups based on equivalent PF states which might come from different paths through an inference algorithm. But it also seems like it could be confusing if, e.g., calling What do you think? |
Re A vs B -- since we expect in normal usage the |
Thanks for raising these questions! I think 1-A sounds like a fine way to go -- or at least, I currently can't think of edge cases where you'd want a stricter equality check. Re 1, I'd maybe check that this is still correct when custom priority weights are used when resampling, as in the second branch of this code: Re A vs. B, I think not checking |
@ztangent I've committed a change which implements 2-A. I'm heading out on vacation now, so I will only be able to respond sporadically for the coming month, but hopefully this is a viable change for now! Re implementation 1 vs 2 -- I switched to implementation 2. (Also, I realize that my proposal for "1" gets the math slightly wrong, by the way. This isn't the reason for the switch, though.) The reason I switched from 1 to 2 is I realized I do not understand what the semantics are supposed to be regarding how the values of You or @alex-lew may understand these semantics, and so know if there is a better implementation of equality for the ParticleFilterState. Or perhaps it is actually the case that the semantics should always that the separation of Anyway, if this is going to require longer discussion, perhaps we could commit this implementation of 2-A for now, and open an issue to discuss potentially changing equality semantics for particle filters. |
Going with 2-A sounds good to me! Yes, on second thought, we probably shouldn't say two particle filters are equal if |
No description provided.