tskit-dev / tskit

Population-scale genomics
MIT License
155 stars 73 forks source link

Recursion depth exceed when generating large random trees #2626

Open hyanwong opened 2 years ago

hyanwong commented 2 years ago

A trivial thing, but this hits python's recursion depth limit:

tskit.Tree.generate_random_binary(1_000_000)

At some point in the distant future we might want to recode generate_random_binary not to use recursion.

jeromekelleher commented 2 years ago

Code here