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

Refactor pedigree simulations to use tables allocated nodes #1186

Closed
jeromekelleher opened this issue Sep 17, 2020 · 2 comments
Closed

Refactor pedigree simulations to use tables allocated nodes #1186

jeromekelleher opened this issue Sep 17, 2020 · 2 comments
Assignees

Comments

@jeromekelleher
Copy link
Member

#1183 made some changes to the pedigree simulations, and the code is in a semi-working state. The new approach is to fully allocate all pedigree individuals and their nodes before the pedigree simulation is run. The simulation then initialises its state from this starting point, and then fills in the edge table with the simulated genetic relationships.

The code isn't currently using the nodes that were input, however, but is creating new nodes as they are needed. It should be a straightforward change to msp_merge_ancestors to use a pre-existing node rather than allocating a new one. There's various notes like this in msprime.c which should help to orient things.

We should also remove the special cases in the inner loops of merge_ancestors for pedigrees. We should be able to do this using the standard populations.

@jeromekelleher
Copy link
Member Author

@DomNelson I think this is the main set of changes that we need to make to the underlying C code. Can you have a look and see how much is involved, please?

@jeromekelleher
Copy link
Member Author

Closed in #1846 and earlier updates.

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

No branches or pull requests

3 participants