The local spin density.
Configurations, then sites, then spin direction. That makes it easy to do something with ensemble.s[...,1].
The spin direction matches the index of tdg.PauliMatrix[1:] so that 0 is in the x direction, for example.
The total spin, summed over sites. Configurations slowest, then spin direction.
The spin direction matches the index of tdg.PauliMatrix[1:] so that 0 is in the x direction, for example.