cclauss commented on issue #8270: 43 Undefined names in Python code
URL: 
https://github.com/apache/incubator-mxnet/issues/8270#issuecomment-409746782
 
 
   
   flake8 testing of https://github.com/apache/incubator-mxnet on Python 3.7.0
   
   $ __flake8 . --count --select=E901,E999,F821,F822,F823 --show-source 
--statistics__
   ```
   
/home/travis/virtualenv/python3.7.0/lib/python3.7/site-packages/pycodestyle.py:113:
 FutureWarning: Possible nested set at position 1
     EXTRANEOUS_WHITESPACE_REGEX = re.compile(r'[[({] | []}),;:]')
   ./example/reinforcement-learning/a3c/a3c.py:206:16: F821 undefined name 
'robo_data'
       dataiter = robo_data.RobosimsDataIter('scenes', args.batch_size, 
args.input_length, web_viz=True)
                  ^
   ./example/ssd/dataset/pycocotools/coco.py:266:41: F821 undefined name 'm'
                           img = np.ones( (m.shape[0], m.shape[1], 3) )
                                           ^
   ./example/ssd/dataset/pycocotools/coco.py:266:53: F821 undefined name 'm'
                           img = np.ones( (m.shape[0], m.shape[1], 3) )
                                                       ^
   ./example/ssd/dataset/pycocotools/coco.py:273:52: F821 undefined name 'm'
                           ax.imshow(np.dstack( (img, m*0.5) ))
                                                      ^
   ./example/ssd/dataset/pycocotools/coco.py:435:16: F821 undefined name 'm'
           return m
                  ^
   ./example/ssd/symbol/common.py:209:23: F821 undefined name 'start_offset'
            min_sizes = [start_offset] + tmp.tolist()
                         ^
   ./example/ssd/symbol/common.py:210:46: F821 undefined name 'start_offset'
            max_sizes = tmp.tolist() + [tmp[-1]+start_offset]
                                                ^
   ./example/fcn-xs/image_segmentaion.py:100:60: F821 undefined name 'ctx'
       fcnxs_args["data"] = mx.nd.array(get_data(args.input), ctx)
                                                              ^
   ./example/fcn-xs/image_segmentaion.py:103:60: F821 undefined name 'ctx'
       fcnxs_args["softmax_label"] = mx.nd.empty(label_shape, ctx)
                                                              ^
   ./example/fcn-xs/image_segmentaion.py:104:26: F821 undefined name 'ctx'
       exector = fcnxs.bind(ctx, fcnxs_args, args_grad=None, grad_req="null", 
aux_states=fcnxs_args)
                            ^
   ./example/neural-style/end_to_end/model_vgg19.py:94:17: F821 undefined name 
'out'
       arg_names = out.list_arguments()
                   ^
   ./example/neural-style/end_to_end/model_vgg19.py:105:16: F821 undefined name 
'out'
       executor = out.bind(ctx=ctx, args=arg_dict, args_grad=[], 
grad_req="null")
                  ^
   ./example/sparse/factorization_machine/metric.py:111:22: F821 undefined name 
'label_zero_num'
           total_area = label_zero_num * label_one_num
                        ^
   ./example/sparse/factorization_machine/metric.py:111:39: F821 undefined name 
'label_one_num'
           total_area = label_zero_num * label_one_num
                                         ^
   ./example/profiler/profiler_executor.py:89:15: F821 undefined name 
'search_plan'
           sym = search_plan(sym, data=data_shapes)
                 ^
   ./example/profiler/profiler_executor.py:89:37: F821 undefined name 
'data_shapes'
           sym = search_plan(sym, data=data_shapes)
                                       ^
   ./python/mxnet/initializer.py:700:20: F821 undefined name 
'_INITIALIZER_REGISTRY'
               init = _INITIALIZER_REGISTRY[klass.lower()](**kwargs)
                      ^
   ./python/mxnet/optimizer.py:718:34: F821 undefined name 'array'
               weight_master_copy = array(weight, ctx=weight.context, 
dtype=numpy.float32)
                                    ^
   ./python/mxnet/optimizer.py:769:16: F821 undefined name 'multiply'
           norm = multiply(v, v).asnumpy().sum()
                  ^
   ./tests/python/unittest/test_engine_import.py:33:13: F821 undefined name 
'reload'
               reload(mxnet)
               ^
   ./tests/nightly/model_backwards_compatibility_check/common.py:214:12: F821 
undefined name 'cmp'
       return cmp(normalize(version1), normalize(version2))
              ^
   ./docs/mxdoc.py:75:16: F821 undefined name 'root_path'
       pdf_path = root_path + '/docs/api/r/mxnet-r-reference-manual.pdf'
                  ^
   22    F821 undefined name 'root_path'
   22
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to