'Returns the current simulation datetime.
Parameters
tz : tzinfo or str, optional
The timezone to return the datetime in. This defaults to utc.
Returns
dt : datetime
The current simulation datetime converted to ``tz``.'

@api_method
@preprocess(tz=coerce_string(pytz.timezone))
@expect_types(tz=optional(tzinfo))
def get_datetime(self, tz=None):

    dt = self.datetime
    assert (dt.tzinfo == pytz.utc), 'Algorithm    should    have    a    utc    datetime'
    if (tz is not None):
        dt = dt.astimezone(tz)
    return dt
