File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -805,15 +805,16 @@ def solve_num_mismatches(ts, k):
805
805
# on how low we can push the HMM precision. We should be able to solve
806
806
# for the optimal value of this parameter such that the magnitude of the
807
807
# values within the HMM are as large as possible (so that we can truncate
808
- # usefully). This value is probably close for k=3 (it fails for k=2).
809
- mu = 1e-2
808
+ # usefully).
809
+ mu = 1e-3
810
810
denom = (1 - mu ) ** k + (n - 1 ) * mu ** k
811
811
r = n * mu ** k / denom
812
812
assert mu < 0.5
813
813
assert r < 0.5
814
814
815
- # Add a tiny bit of extra mass for recombination so that we deterministically
815
+ # Add a little bit of extra mass for recombination so that we deterministically
816
816
# chose to recombine over k mutations
817
+ # NOTE: the magnitude of this value will depend also on mu, see above.
817
818
r += r * 0.01
818
819
ls_recomb = np .full (m - 1 , r )
819
820
ls_mismatch = np .full (m , mu )
You can’t perform that action at this time.
0 commit comments