Class implementing a flush event mechanism for neuron models. More...
#include <flush_event_mechanism.h>
Public Member Functions | |
| FlushEventMechanism () | |
| Default constructor. | |
| FlushEventMechanism (const FlushEventMechanism &n) | |
| Copy constructor. | |
| virtual | ~FlushEventMechanism ()=default |
| Destructor. | |
| void | set_last_event_time (const long last_event_time) |
| Sets the time the neuron last sent an event (spike or flush event). | |
| long | get_last_event_time () const |
| Gets the last time the neuron sent an event (spike or flush event). | |
| void | pre_run_hook () |
| Re-calculates dependent parameters. | |
| bool | flush_event_is_due (const long current_time) const |
| Checks if a flush event is due at the current time. | |
| void | get_status (Dictionary &d) const |
| Retrieves parameters and adds them to the status dictionary. | |
| void | set_status (const Dictionary &d, Node *node, const bool check_eprop_constraint=false) |
| Sets and validates parameters from the status dictionary. | |
Protected Attributes | |
| double | flush_event_send_interval_ |
| Interval since previous event after which a flush event is sent (ms). | |
| long | flush_event_send_interval_steps_ |
| Interval since previous event after which a flush event is sent (steps). | |
| long | last_event_time_ |
| Time of last spike or flush event (steps). | |
Class implementing a flush event mechanism for neuron models.
This class implements a flush event mechanism for neuron models that send flush events after prolonged periods without spike emission.
| nest::FlushEventMechanism::FlushEventMechanism | ( | ) |
Default constructor.
| nest::FlushEventMechanism::FlushEventMechanism | ( | const FlushEventMechanism & | n | ) |
Copy constructor.
| n | The other object to copy. |
|
virtualdefault |
Destructor.
|
inline |
Checks if a flush event is due at the current time.
| current_time | The current simulation time (steps). |
References flush_event_send_interval_steps_, and last_event_time_.
Referenced by nest::eprop_iaf::update(), nest::eprop_iaf_adapt::update(), nest::eprop_iaf_adapt_bsshslm_2020::update(), nest::eprop_iaf_bsshslm_2020::update(), nest::eprop_iaf_psc_delta::update(), nest::eprop_iaf_psc_delta_adapt::update(), and nest::parrot_neuron::update().
|
inline |
Gets the last time the neuron sent an event (spike or flush event).
References last_event_time_.
| void nest::FlushEventMechanism::get_status | ( | Dictionary & | d | ) | const |
Retrieves parameters and adds them to the status dictionary.
| d | Dictionary to which parameters are added. |
References nest::names::flush_event_send_interval(), and flush_event_send_interval_.
Referenced by nest::parrot_neuron::get_status(), and nest::EpropArchivingNodeRecurrent< hist_shift_required >::get_status().
| void nest::FlushEventMechanism::pre_run_hook | ( | ) |
Re-calculates dependent parameters.
References flush_event_send_interval_, flush_event_send_interval_steps_, and nest::Time::get_steps().
Referenced by nest::eprop_iaf::pre_run_hook(), nest::eprop_iaf_adapt::pre_run_hook(), nest::eprop_iaf_adapt_bsshslm_2020::pre_run_hook(), nest::eprop_iaf_bsshslm_2020::pre_run_hook(), nest::eprop_iaf_psc_delta::pre_run_hook(), nest::eprop_iaf_psc_delta_adapt::pre_run_hook(), and nest::parrot_neuron::pre_run_hook().
|
inline |
Sets the time the neuron last sent an event (spike or flush event).
| last_event_time | The time of the last event (steps). |
References last_event_time_.
Referenced by nest::eprop_iaf::update(), nest::eprop_iaf_adapt::update(), nest::eprop_iaf_adapt_bsshslm_2020::update(), nest::eprop_iaf_bsshslm_2020::update(), nest::eprop_iaf_psc_delta::update(), nest::eprop_iaf_psc_delta_adapt::update(), and nest::parrot_neuron::update().
| void nest::FlushEventMechanism::set_status | ( | const Dictionary & | d, |
| Node * | node, | ||
| const bool | check_eprop_constraint = false |
||
| ) |
Sets and validates parameters from the status dictionary.
| d | Dictionary with parameters. |
| check_eprop_constraint | If true, validate that flush_event_send_interval >= eprop_update_interval. |
References nest::names::flush_event_send_interval(), flush_event_send_interval_, nest::SimulationManager::get_eprop_update_interval(), nest::Time::get_ms(), nest::kernel(), nest::KernelManager::simulation_manager, and nest::update_value_param().
Referenced by nest::parrot_neuron::set_status(), and nest::EpropArchivingNodeRecurrent< hist_shift_required >::set_status().
|
protected |
Interval since previous event after which a flush event is sent (ms).
Referenced by get_status(), pre_run_hook(), and set_status().
|
protected |
Interval since previous event after which a flush event is sent (steps).
Referenced by flush_event_is_due(), and pre_run_hook().
|
protected |
Time of last spike or flush event (steps).
Referenced by flush_event_is_due(), get_last_event_time(), and set_last_event_time().