-
Notifications
You must be signed in to change notification settings - Fork 12
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 new balance edge algos & reversible ReCom #94
base: main
Are you sure you want to change the base?
Conversation
I agree that this PR is too big. I would like the PR to be split further and with unit tests to feel better about it. One way you could break this PR down could be;
I do understand that this seems like a lot of work. Let's talk about this though! |
Let's split things into three files:
@bsuwal suggests splitting the balanced cuts code out into a separate PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything looks reasonable to me upon skimming! I see resumable functions, as per our meetings I'm guessing we're going to change that potentially?
src/recom.jl
Outdated
tree_fn::Function=wilson_ust, | ||
balance_edge_fn::Function=memoized_balance_edges, | ||
node_repeats::Int=1)::Union{RecomProposal, String} | ||
"""TODO""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be done! heh
Although this is a breaking change, this brings GerryChain Julia more in line with GerryChain Python and allows the user to save and export state more easily. This API is different from the one proposed in #94 in that it returns a Partition object and the scores.
* Make recom and flip chains an iterable a la GerryChain Python Although this is a breaking change, this brings GerryChain Julia more in line with GerryChain Python and allows the user to save and export state more easily. This API is different from the one proposed in #94 in that it returns a Partition object and the scores. * Add recom_chain and flip_chain functions for backwards compat. The iterators are now exposed in `recom_chain_iter` and `flip_chain_iter` respectively to avoid any breaking changes. * Update type signatures of the iterator APIs * Point to issue on GitHub with the bug in ResumableFunctions.jl * Export iter API * Add note about `Partition` being mutable and changing in-place
This PR is too big, which probably means the balance edge algorithms should live in their own file so that they can be reviewed separately. Right now, this PR contains: