Cypress  1.0
C++ Spiking Neural Network Simulation Framework
Public Member Functions | List of all members
cypress::PowerManagementBackend Class Reference

#include <power.hpp>

Inheritance diagram for cypress::PowerManagementBackend:
Inheritance graph
[legend]
Collaboration diagram for cypress::PowerManagementBackend:
Collaboration graph
[legend]

Public Member Functions

 PowerManagementBackend (std::shared_ptr< PowerDevice > device, std::unique_ptr< Backend > backend)
 
 PowerManagementBackend (std::unique_ptr< Backend > backend, const std::string &config_filename="")
 
 ~PowerManagementBackend () override
 
std::unordered_set< const NeuronType * > supported_neuron_types () const override
 
std::string name () const override
 
void run (NetworkBase &network, Real duration=0.0) const
 

Detailed Description

The PowerManagementBackend is responsible for switching neuromorphic hardware devices on and off when necessary and to automatically reset them in case there is an error during the execution, which are sometimes caused by buggy firmware. E.g. the Spikey device sometimes looses the USB connection, which can only be solved by a power cycle. Furthermore, due to annoying noise being emitted from the device, it is extremely important for the sanity of the people sitting in the same room, that the device is switched on exactly if experments are running.

Constructor & Destructor Documentation

cypress::PowerManagementBackend::PowerManagementBackend ( std::shared_ptr< PowerDevice device,
std::unique_ptr< Backend backend 
)

Creates a new PowerManagementBackend instance.

Parameters
deviceis the device which is responsible for switching the power to the neuromorphic hardware.
backendis the backend which actually executes the network.
cypress::PowerManagementBackend::PowerManagementBackend ( std::unique_ptr< Backend backend,
const std::string &  config_filename = "" 
)
cypress::PowerManagementBackend::~PowerManagementBackend ( )
override

Destroys the PowerManagementBackend backend instance.

Member Function Documentation

std::string cypress::PowerManagementBackend::name ( ) const
inlineoverridevirtual

Returns the canonical name of the backend. Forward the call to the actual backend being wrapped by the PowerManagementBackend.

Implements cypress::Backend.

void cypress::Backend::run ( NetworkBase network,
Real  duration = 0.0 
) const
inherited

Simulates the given spiking neural network for the given duration.

Parameters
networkis the network that should be simulated. The simulation result will be written to the network instance.
durationis the duration for which the network should be simulated.
std::unordered_set<const NeuronType *> cypress::PowerManagementBackend::supported_neuron_types ( ) const
inlineoverridevirtual

Returns the neuron types supported by the actual backend.

Implements cypress::Backend.


The documentation for this class was generated from the following file: