change should not be complex dtype, which would happen if u=complex. Fixed this by not specifying dtype