CPPStandaloneCodeObject class¶
(Shortest import: from brian2.devices.cpp_standalone import CPPStandaloneCodeObject)
-
class
brian2.devices.cpp_standalone.codeobject.CPPStandaloneCodeObject(owner, code, variables, variable_indices, template_name, template_source, compiler_kwds, name='codeobject*')[source]¶ Bases:
brian2.codegen.codeobject.CodeObjectC++ standalone code object
The
codeshould be aMultiTemplateobject with two macros defined,main(for the main loop code) andsupport_codefor any support code (e.g. function definitions).Methods
__call__(**kwds)Call self as a function. run()Runs the code in the namespace. Details