@@ -162,13 +162,13 @@ def perform(self, *args, **kwargs):
162162 raise NotImplementedError ("Test Op should not be present in final graph" )
163163
164164
165- test_op = MyTestOp ()
165+ my_test_op = MyTestOp ()
166166
167167
168168def test_vectorize_node_default_signature ():
169169 vec = tensor (shape = (None ,))
170170 mat = tensor (shape = (5 , None ))
171- node = test_op .make_node (vec , mat )
171+ node = my_test_op .make_node (vec , mat )
172172
173173 vect_node = vectorize_node (node , mat , mat )
174174 assert isinstance (vect_node .op , Blockwise ) and isinstance (
@@ -179,9 +179,9 @@ def test_vectorize_node_default_signature():
179179 with pytest .raises (
180180 ValueError , match = "Signature not provided nor found in core_op MyTestOp"
181181 ):
182- Blockwise (test_op )
182+ Blockwise (my_test_op )
183183
184- vect_node = Blockwise (test_op , signature = "(m),(n)->(m),(n)" ).make_node (vec , mat )
184+ vect_node = Blockwise (my_test_op , signature = "(m),(n)->(m),(n)" ).make_node (vec , mat )
185185 assert vect_node .outputs [0 ].type .shape == (
186186 5 ,
187187 None ,
@@ -198,7 +198,7 @@ def test_blockwise_shape():
198198 inp_test = np .zeros ((5 , 4 , 3 ), dtype = config .floatX )
199199
200200 # Shape can be inferred from inputs
201- op = Blockwise (test_op , signature = "(m, n) -> (n, m)" )
201+ op = Blockwise (my_test_op , signature = "(m, n) -> (n, m)" )
202202 out = op (inp )
203203 assert out .type .shape == (5 , None , None )
204204
@@ -210,7 +210,7 @@ def test_blockwise_shape():
210210 assert tuple (shape_fn (inp_test )) == (5 , 3 , 4 )
211211
212212 # Shape can only be partially inferred from inputs
213- op = Blockwise (test_op , signature = "(m, n) -> (m, k)" )
213+ op = Blockwise (my_test_op , signature = "(m, n) -> (m, k)" )
214214 out = op (inp )
215215 assert out .type .shape == (5 , None , None )
216216
@@ -233,7 +233,7 @@ def test_blockwise_shape():
233233 inp1_test = np .zeros ((7 , 1 , 4 , 3 ), dtype = config .floatX )
234234 inp2_test = np .zeros ((1 , 5 , 4 , 3 ), dtype = config .floatX )
235235
236- op = Blockwise (test_op , signature = "(m, n), (m, n) -> (n, m), (m, k)" )
236+ op = Blockwise (my_test_op , signature = "(m, n), (m, n) -> (n, m), (m, k)" )
237237 outs = op (inp1 , inp2 )
238238 assert outs [0 ].type .shape == (7 , 5 , None , None )
239239 assert outs [1 ].type .shape == (7 , 5 , None , None )
0 commit comments