Skip to content

Commit

Permalink
pylint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian-B committed Jul 5, 2024
1 parent 62c44e2 commit cdad245
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion examples/breakout/breakout_simple_connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@

# non-SpiNNaker imports
import matplotlib.pyplot as plt
import pyNN.spiNNaker as p
from pyNN.utility.plotting import Figure, Panel

# SpiNNaker imports
from spinn_gym.games.breakout.breakout_sim import get_scores
from spinn_gym.games.breakout.random_breakout import RandomBreakout
import pyNN.spiNNaker as p

breakout = RandomBreakout()

Expand Down
2 changes: 1 addition & 1 deletion spinn_gym/games/breakout/breakout_sim.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ def get_hidden_to_decision_connections(pop_size, weight):

def clean_connection(data):
clean_conn = []
for i, connection in enumerate(data.connections):
for connection in data.connections:
for c in connection:
new_c = (int(c[0]), int(c[1]), float(c[2]), float(c[3]))
clean_conn.append(new_c)
Expand Down
4 changes: 3 additions & 1 deletion spinn_gym/games/breakout/visualiser/visualiser.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
# along with this program. If not, see <https://www.gnu.org/licenses/>.

from collections import deque
import cv2
import datetime
import enum
import os

import cv2
import numpy as np
import matplotlib.colors as col
import matplotlib.pyplot as plt
Expand Down Expand Up @@ -62,6 +62,8 @@ class Visualiser(object):
def __init__(self, key_input_connection=None,
scale=4, x_factor=8, y_factor=8, x_bits=8, y_bits=8, fps=60,
live_pops=None, live_duration=5000, video_out=False):
# cv2 is impossible to pylint
# pylint: disable=no-member
self._connection_ready = False
self.running = True
self.do_update = False
Expand Down

0 comments on commit cdad245

Please sign in to comment.