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

#include <nmpi.hpp>

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

Classes

class  InvalidCommandLine
 
class  NoNMPIPlatform
 

Public Member Functions

 NMPI (std::unique_ptr< Backend > pynn, int &argc, const char *argv[], const std::vector< std::string > &files=std::vector< std::string >(), bool scan_args=true)
 
 NMPI (const std::string &pynn_backend, int &argc, const char *argv[], const std::vector< std::string > &files=std::vector< std::string >(), bool scan_args=true)
 
 ~NMPI () 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
 

Static Public Member Functions

static bool check_args (int argc, const char *argv[])
 

Detailed Description

The NMPI backend executes the program on a Neuromorphic Platform Interface server.

Constructor & Destructor Documentation

cypress::NMPI::NMPI ( std::unique_ptr< Backend pynn,
int &  argc,
const char *  argv[],
const std::vector< std::string > &  files = std::vector< std::string >(),
bool  scan_args = true 
)

Creates a new instance of the NMPI backend. On the client computer, the constructor does not return. Instead, it uploads the current executable to the NMPI server and runs it there.

Parameters
pynnis a pointer at the PyNN backend that should be used.
argcis the number of command line arguments passed at the executable.
argvis the array containing the command line arguments.
filesis a vector containing the names of additional files that should be uploaded to the neuromorphic compute platform.
scan_argsif true, automagically scans the command line arguments for for filenames and uploads these files too.
cypress::NMPI::NMPI ( const std::string &  pynn_backend,
int &  argc,
const char *  argv[],
const std::vector< std::string > &  files = std::vector< std::string >(),
bool  scan_args = true 
)

Creates a new instance of the NMPI backend. On the client computer, the constructor does not return. Instead, it uploads the current executable to the NMPI server and runs it there.

Parameters
pynn_backendis the name of the pynn backend that should be used on the neuromorphic compute platform.
argvis the array containing the command line arguments.
filesis a vector containing the names of additional files that should be uploaded to the neuromorphic compute platform.
scan_argsif true, automagically scans the command line arguments for for filenames and uploads these files too.
cypress::NMPI::~NMPI ( )
override

Destructor. Destroys the PyNN backend.

Member Function Documentation

static bool cypress::NMPI::check_args ( int  argc,
const char *  argv[] 
)
static

Returns true if the given arguments consititure a call on the NMPI server in which case no further checking should be performed.

std::string cypress::NMPI::name ( ) const
overridevirtual

Returns the canonical name of the backend.

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::NMPI::supported_neuron_types ( ) const
overridevirtual

Returns the neuron types supported by the actual backend.

Implements cypress::Backend.


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