5480680b27b47a85499834c35c93b4c599a33101,brian2/synapses/synapses.py,Synapses,_create_variables,#Synapses#,818

Before Change


                // shouldn"t directly access the specifier.array attribute but
                // use specifier.get_value() to get a reference to the underlying
                // array
                v.update({eq.varname: DynamicArrayVariable(eq.varname,
                                                           eq.unit,
                                                           array,
                                                           group_name=self.name,
                                                           constant=constant,
                                                           is_bool=eq.is_bool)})
                // Register the array with the `SynapticIndex` object so it gets
                // automatically resized
                self.item_mapping.register_variable(array)
            elif eq.type == STATIC_EQUATION:

After Change


                                                     group_name=self.name,
                                                     constant=constant,
                                                     is_bool=eq.is_bool)
                if eq.varname in self.variable_indices:
                    // we are overwriting a postsynaptic variable of the same
                    // name, delete the reference to the postsynaptic index
                    del self.variable_indices[eq.varname]
                // Register the array with the `SynapticItemMapping` object so
                // it gets automatically resized
                self.item_mapping.register_variable(array)
            elif eq.type == STATIC_EQUATION:
                v.update({eq.varname: Subexpression(eq.unit,
                                                    brian_prefs["core.default_scalar_dtype"],
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: brian-team/brian2
Commit Name: 5480680b27b47a85499834c35c93b4c599a33101
Time: 2013-08-18
Author: marcel.stimberg@ens.fr
File Name: brian2/synapses/synapses.py
Class Name: Synapses
Method Name: _create_variables


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 983aedb23057629605c8a7c8d9757945651d48f5
Time: 2015-03-27
Author: yuyantingzero@gmail.com
File Name: perfkitbenchmarker/packages/fio.py
Class Name:
Method Name: ParseJobFile


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 596116954853f7476017242af09580eb9b6dcea2
Time: 2015-03-26
Author: yuyantingzero@gmail.com
File Name: perfkitbenchmarker/packages/fio.py
Class Name:
Method Name: ParseJobFile