Make _get_dt a bit faster by replacing hasattr(...) by try/except
(_get_dt is used every timestep, therefore small improvements here can
have a considerable impact).
Increase the perfomance of the unitless state variable lookup in Group