TypeError: unhashable type: 'numpy.ndarray' for nested lists

I guess the error is raised in data.matrices2mol (which I don’t know how it’s implemented), as a plain list comprehension works:

m1 = [(n_, e_) for n_, e_ in zip(n, e)]