flake8 compliance (except for PyQt5Gui)
This commit is contained in:
@@ -42,6 +42,7 @@ class X:
|
|||||||
|
|
||||||
return x
|
return x
|
||||||
|
|
||||||
|
|
||||||
class Y:
|
class Y:
|
||||||
|
|
||||||
def eval(self, x, y):
|
def eval(self, x, y):
|
||||||
@@ -82,6 +83,7 @@ class Times:
|
|||||||
|
|
||||||
return self.lhs.eval(x, y) * self.rhs.eval(x, y)
|
return self.lhs.eval(x, y) * self.rhs.eval(x, y)
|
||||||
|
|
||||||
|
|
||||||
def buildExpr(prob=0.99):
|
def buildExpr(prob=0.99):
|
||||||
|
|
||||||
if random.random() < prob:
|
if random.random() < prob:
|
||||||
@@ -89,6 +91,7 @@ def buildExpr(prob = 0.99):
|
|||||||
else:
|
else:
|
||||||
return random.choice([X, Y])()
|
return random.choice([X, Y])()
|
||||||
|
|
||||||
|
|
||||||
def plotIntensity(exp, pixelsPerUnit=150):
|
def plotIntensity(exp, pixelsPerUnit=150):
|
||||||
|
|
||||||
canvasWidth = 2 * pixelsPerUnit + 1
|
canvasWidth = 2 * pixelsPerUnit + 1
|
||||||
@@ -107,6 +110,7 @@ def plotIntensity(exp, pixelsPerUnit = 150):
|
|||||||
|
|
||||||
return canvas
|
return canvas
|
||||||
|
|
||||||
|
|
||||||
def plotColor(redExp, greenExp, blueExp, pixelsPerUnit=150):
|
def plotColor(redExp, greenExp, blueExp, pixelsPerUnit=150):
|
||||||
|
|
||||||
redPlane = plotIntensity(redExp, pixelsPerUnit)
|
redPlane = plotIntensity(redExp, pixelsPerUnit)
|
||||||
|
|||||||
Reference in New Issue
Block a user