Inform icon indicating copy to clipboard operation
Inform copied to clipboard

Segmentation fault when computing transfer entropy on linux_64

Open geofurb opened this issue 3 years ago • 0 comments

The issue appears to be occurring with PyInform, but I believe similar to #85 this is an issue with the underlying Inform binary. Applying the update from #85 does not resolve this issue, so it appears to be a separate problem.

import numpy as np
import pyinform

a = np.random.rand(4000) > 0.25
b = np.random.rand(4000) > 0.40

print(a.dtype,b.dtype)
for k in range(1, 100):
    print(k, pyinform.transfer_entropy(a, b, k=k))

Result: Segfault at k=30

It may be informative that this second example segfaults at k=19:

import numpy as np
import pyinform

c = np.random.randint(0, 3, 4000)
d = np.random.randint(0, 2, 4000)

print(c.dtype,d.dtype)
for k in range(1, 100):
    print(k, pyinform.transfer_entropy(c, d, k=k))

Segfault is consistent on two machines: Ubuntu 18.04 with i7-5820K, 128 GB RAM and Ubuntu 22.04 with i7-11800H, 64 GB RAM

geofurb avatar Jul 25 '22 08:07 geofurb