Skip to content

Bug in simplify with KEEP_UNARY_IN_INDIVIDUALS #1154

@hyanwong

Description

@hyanwong

Yes, this really is a simplify bug, which is my own fault. In f2d906d I inserted a check to see if the node being simplified has an individual:

&& (self->tables->nodes.individual[input_id] != TSK_NULL)) {

But it seems that input_id here does not correspond to the node number in the current self->tables->nodes - I'm assuming it's been changed already by some previous node jiggling in the simplification algorithm, but the tables haven't been updated. (see below: I'm not sure this is the problem, actually)

This is hard to test in python, because keep_unary_in_individuals is not an option to the simplify command yet: it's only in the C interface. But hopefully someone who knows about simplify can verify that my triaging is correct. Otherwise I can post a tree sequence where this causes a problem, and link to my branch where I've implemented keep_unary_in_individuals in python.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions