@@ -41,6 +41,7 @@ def check(instance, pattern):
41
41
42
42
for key_group in KEYGROUP_SET :
43
43
for index , attr in enumerate (key_group ):
44
+
44
45
def gen_property (attr , attr_idx , key_group ):
45
46
checker = make_valid_attribs_checker (key_group )
46
47
@@ -121,7 +122,7 @@ def _linearize_entry_id(self, *args):
121
122
if len (args ) == 1 and isinstance (args [0 ], (list , tuple )):
122
123
args = args [0 ]
123
124
if len (args ) == 1 :
124
- args = args + (0 ,)
125
+ args = args + (0 , )
125
126
# TODO(#1004): See if it's possible to support indexing at runtime
126
127
for i , a in enumerate (args ):
127
128
if not isinstance (a , int ):
@@ -244,10 +245,8 @@ def _subscript(self, is_global_mat, *indices):
244
245
return self .any_array_access .subscript (i , j )
245
246
if self .local_tensor_proxy is not None :
246
247
if len (indices ) == 1 :
247
- return impl .make_index_expr (self .local_tensor_proxy ,
248
- (i ,))
249
- return impl .make_index_expr (self .local_tensor_proxy ,
250
- (i , j ))
248
+ return impl .make_index_expr (self .local_tensor_proxy , (i , ))
249
+ return impl .make_index_expr (self .local_tensor_proxy , (i , j ))
251
250
if impl .current_cfg (
252
251
).dynamic_index and is_global_mat and self .dynamic_index_stride :
253
252
return impl .make_stride_expr (self .entries [0 ].ptr , (i , j ),
@@ -320,7 +319,7 @@ def with_dynamic_index(self, arr, dt):
320
319
list ([
321
320
impl .make_index_expr (
322
321
local_tensor_proxy ,
323
- (expr .Expr (i , dtype = primitive_types .i32 ),))
322
+ (expr .Expr (i , dtype = primitive_types .i32 ), ))
324
323
]))
325
324
return local_tensor_proxy , mat
326
325
0 commit comments