Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ def receive_spikes(label, _time, neuron_ids):
# reaches the end
loop_forward = []
loop_backward = []
for i in range(0, n_neurons - 1):
for i in range(n_neurons - 1):
loop_forward.append((i, (i + 1) % n_neurons, weight_to_spike, 3))
loop_backward.append(((i + 1) % n_neurons, i, weight_to_spike, 3))
Frontend.Projection(pop_forward, pop_forward,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def __init__(self):
label='spike_injector_backward')
else:
spike_times = []
for _ in range(0, self.n_neurons):
for _ in range(self.n_neurons):
spike_times.append([])
spike_times[0] = [0]
spike_times[20] = [(run_time / 100) * 20]
Expand All @@ -142,7 +142,7 @@ def __init__(self):
spike_times[80] = [(run_time / 100) * 80]
cell_params_forward = {'spike_times': spike_times}
spike_times_backwards = []
for _ in range(0, self.n_neurons):
for _ in range(self.n_neurons):
spike_times_backwards.append([])
spike_times_backwards[0] = [(run_time / 100) * 80]
spike_times_backwards[20] = [(run_time / 100) * 60]
Expand Down Expand Up @@ -175,7 +175,7 @@ def __init__(self):
# it reaches the end
loop_forward = []
loop_backward = []
for i in range(0, self.n_neurons - 1):
for i in range(self.n_neurons - 1):
loop_forward.append((i, (i + 1) %
self.n_neurons, weight_to_spike, 3))
loop_backward.append(((i + 1) %
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
delay = 17

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
singleConnection = (i, ((i + 1) % nNeurons), weight_to_spike, delay)
loopConnections.append(singleConnection)

Expand Down
2 changes: 1 addition & 1 deletion examples/extra_models_examples/LGN_Izhikevich.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def get_mean_rate(numCells, population):
"""
firing_rate = [] # format = < neuron_id, rate (spikes/ms) >

for index in range(0, numCells):
for index in range(numCells):
rate = len(population.segments[0].spiketrains[index])/TotalDuration
firing_rate.append(rate)

Expand Down
2 changes: 1 addition & 1 deletion examples/extra_models_examples/synfire_if_curr_dual_exp.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def run_script(*, split: bool = False) -> None:
delay = 17

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
singleConnection = ((i, (i + 1) % nNeurons, weight_to_spike, delay))
loopConnections.append(singleConnection)

Expand Down
2 changes: 1 addition & 1 deletion examples/synfire_if_cond_exp.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
delay = 17

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
singleConnection = ((i, (i + 1) % nNeurons, weight_to_spike, delay))
loopConnections.append(singleConnection)

Expand Down
2 changes: 1 addition & 1 deletion examples/synfire_if_curr_exp.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
delay = 17

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
singleConnection = ((i, (i + 1) % nNeurons, weight_to_spike, delay))
loopConnections.append(singleConnection)

Expand Down
2 changes: 1 addition & 1 deletion examples/synfire_if_curr_exp_get_weights.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
delay = 17

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
singleConnection = ((i, (i + 1) % nNeurons, weight_to_spike, delay))
loopConnections.append(singleConnection)

Expand Down
2 changes: 1 addition & 1 deletion examples/synfire_if_curr_exp_large_array.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

connections = []
reverseConnections = []
for i in range(0, nNeurons - 1):
for i in range(nNeurons - 1):
connections.append((i, (i + 1) % nNeurons, weight_to_spike, delay))
reverseConnections.append(((i + 1) % nNeurons, i, weight_to_spike, delay))

Expand Down
2 changes: 1 addition & 1 deletion examples/synfire_if_curr_exp_random.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
delay = RandomDistribution("uniform", low=1, high=max_delay)

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
delay_value = delay.next()
singleConnection = (i, ((i + 1) % nNeurons), weight_to_spike, delay_value)
loopConnections.append(singleConnection)
Expand Down
2 changes: 1 addition & 1 deletion examples/synfire_izk_curr_exp.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
delay = 1

loopConnections = []
for i in range(0, nNeurons):
for i in range(nNeurons):
singleConnection = ((i, (i + 1) % nNeurons, weight_to_spike, delay))
loopConnections.append(singleConnection)

Expand Down
Loading