View source on GitHub |
Indicator for periodically resetting the tree state after a certain time.
Inherits From: RestartIndicator
tf_privacy.restart_query.PeriodicTimeRestartIndicator(
period_seconds: float
)
The indicator will maintain a state to track the previous restart time.
Args | |
---|---|
period_seconds
|
The next function will return True if called after
period_seconds .
|
Methods
initialize
@tf.function
initialize()
Returns initial time as state.
next
@tf.function
next( state )
Gets next bool indicator and advances the state.
Args | |
---|---|
state
|
The current state. |
Returns | |
---|---|
A pair (value, new_state) where value is the bool indicator and new_state of time. |