Changeset 707
- Timestamp:
- 09/30/17 14:53:15 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
mds-and-trees/tree-genealogy.py
r702 r707 698 698 default_props = ["Time", "FromIDs", "ID", "Operation", "Inherited"] 699 699 700 merged_with_virtual_parent = [] 701 700 702 self.ids = {} 701 703 def get_id(id, createOnError = True): … … 773 775 parent_id = get_id(creature["FromIDs"][i]) 774 776 else: 777 if creature["FromIDs"][i] not in merged_with_virtual_parent: 778 merged_with_virtual_parent.append(creature["FromIDs"][i]) 775 779 parent_id = get_id("virtual_parent") 776 780 inherited = (creature["Inherited"][i] if 'Inherited' in creature else 1) … … 806 810 break 807 811 812 print("WARNING: merging individuals: " + str(merged_with_virtual_parent) + " with a virtual parent node!") 813 808 814 for k in range(len(self.parents)): 809 815 v = self.parents[k]
Note: See TracChangeset
for help on using the changeset viewer.