brian2tools.baseexport.collector module¶
The file contains simple functions to collect information from BrianObjects and represent them in a standard dictionary format. The parts of the file shall be reused with standard format exporter.
-
brian2tools.baseexport.collector.
collect_Equations
(equations)[source]¶ Collect model equations of the NeuronGroup
Parameters: equations (brian2.equations.equations.Equations) – model equations object Returns: eqn_dict – Dictionary with extracted information Return type: dict
-
brian2tools.baseexport.collector.
collect_EventMonitor
(event_mon)[source]¶ Collect details of
EventMonitor
class and return them in dictionary formatParameters: event_mon (brian2.EventMonitor) – EventMonitor object Returns: event_mon_dict – Dictionary representation of the collected details Return type: dict
-
brian2tools.baseexport.collector.
collect_Events
(group)[source]¶ Collect Events (spiking) of the NeuronGroup
Parameters: group (brian2.groups.neurongroup.NeuronGroup) – NeuronGroup object Returns: - event_dict (dict) – Dictionary with extracted information
- event_identifiers (set) – Set of identifiers related to events
-
brian2tools.baseexport.collector.
collect_NeuronGroup
(group, run_namespace)[source]¶ Collect information from
brian2.groups.neurongroup.NeuronGroup
and return them in a dictionary formatParameters: - group (brian2.groups.neurongroup.NeuronGroup) – NeuronGroup object
- run_namespace (dict) – Namespace dictionary
Returns: neuron_dict – Dictionary with extracted information
Return type:
-
brian2tools.baseexport.collector.
collect_PoissonGroup
(poisson_grp, run_namespace)[source]¶ Extract information from ‘brian2.input.poissongroup.PoissonGroup’ and represent them in a dictionary format
Parameters: - poisson_grp (brian2.input.poissongroup.PoissonGroup) – PoissonGroup object
- run_namespace (dict) – Namespace dictionary
Returns: poisson_grp_dict – Dictionary with extracted information
Return type:
-
brian2tools.baseexport.collector.
collect_PoissonInput
(poinp, run_namespace)[source]¶ Collect details of
PoissonInput
and represent them in dictionaryParameters: - poinp (brian2.input.poissoninput.PoissonInput) – PoissonInput object
- run_namespace (dict) – Namespace dictionary
Returns: poinp_dict – Dictionary representation of the collected details
Return type:
-
brian2tools.baseexport.collector.
collect_PopulationRateMonitor
(poprate_mon)[source]¶ Represent required details of PopulationRateMonitor in dictionary format
Parameters: poprate_mon (brian2.monitors.ratemonitor.PopulationRateMonitor) – PopulationRateMonitor class object Returns: poprate_mon_dict – Dictionary format of the details collected Return type: dict
-
brian2tools.baseexport.collector.
collect_SpikeGenerator
(spike_gen, run_namespace)[source]¶ Extract information from ‘brian2.input.spikegeneratorgroup.SpikeGeneratorGroup’and represent them in a dictionary format
Parameters: - spike_gen (brian2.input.spikegeneratorgroup.SpikeGeneratorGroup) – SpikeGenerator object
- run_namespace (dict) – Namespace dictionary
Returns: spikegen_dict – Dictionary with extracted information
Return type:
-
brian2tools.baseexport.collector.
collect_SpikeMonitor
(spike_mon)[source]¶ Collect details of
brian2.monitors.spikemonitor.SpikeMonitor
and return them in dictionary formatParameters: spike_mon (brian2.monitors.spikemonitor.SpikeMonitor) – SpikeMonitor object Returns: spike_mon_dict – Dictionary representation of the collected details Return type: dict
-
brian2tools.baseexport.collector.
collect_SpikeSource
(source)[source]¶ Check SpikeSource and collect details
Parameters: source ( brian2.core.spikesource.SpikeSource
) – SpikeSource object
-
brian2tools.baseexport.collector.
collect_StateMonitor
(state_mon)[source]¶ Collect details of
brian2.monitors.statemonitor.StateMonitor
and return them in dictionary formatParameters: state_mon (brian2.monitors.statemonitor.StateMonitor) – StateMonitor object Returns: state_mon_dict – Dictionary representation of the collected details Return type: dict
-
brian2tools.baseexport.collector.
collect_Synapses
(synapses, run_namespace)[source]¶ Collect information from
brian2.synapses.synapses.Synapses
and represent them in dictionary formatParameters: - synapses (brian2.synapses.synapses.Synapses) – Synapses object
- run_namespace (dict) – Namespace dictionary
Returns: synapse_dict – Standard dictionary format with collected information
Return type: