Thank you, Joshua and Christian.
I revised my code to make the two imp_regions unique. However, my problem persists. To be clear, my code doesn't crash.
I think it has something to do with my dynamic retagging procedure. I use the entire list of mesh elements, assuming this includes the bath, and retag the bath elements with IDs that should be the tissues' ID (see code below).
elems = np.loadtxt(tissue+'.elem', skiprows=1, usecols=(1,2,3,4),dtype=int)
pts = np.loadtxt(tissue+'.pts', skiprows=1)
Do you know a way to isolate just the tissue elements?