Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing import statements for TextCNN and numpy #82

Closed
cclauss opened this issue Sep 6, 2018 · 0 comments
Closed

Missing import statements for TextCNN and numpy #82

cclauss opened this issue Sep 6, 2018 · 0 comments

Comments

@cclauss
Copy link
Contributor

cclauss commented Sep 6, 2018

  • TextCNN is not properly imported in ./a02_TextCNN/p7_TextCNN_model_multilayers.py
  • numpy is not properly imported as np in ./a00_boosting/a08_boosting.py
  • predict is an undefined name in ./a07_Transformer/a2_predict.py
  • reload() was moved in Python 3

flake8 testing of https://github.com/brightmart/text_classification 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'[[({] | []}),;:]')
./a08_predict_ensemble.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a09_DynamicMemoryNet/a8_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a09_DynamicMemoryNet/a8_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a07_Transformer/a2_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a07_Transformer/a2_train_classification.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a07_Transformer/a2_predict_classification.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a07_Transformer/a2_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a07_Transformer/a2_predict.py:102:55: F821 undefined name 'predict'
            print("===============>",start,"predict:",predict)
                                                      ^
./aa1_data_util/3_process_zhihu_question_topic_relation.py:3:1: F821 undefined name 'reload'
reload(sys)
^
./aa1_data_util/2_predict_zhihu_get_question_representation.py:3:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/p7_TextCNN_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/p7_TextCNN_model_multilayers.py:166:13: F821 undefined name 'TextCNN'
    textRNN=TextCNN(filter_sizes,num_filters,num_classes, learning_rate, batch_size, decay_steps, decay_rate,sequence_length,vocab_size,embed_size,is_training,multi_label_flag=multi_label_flag)
            ^
./a02_TextCNN/other_experiement/p7_TextCNN_predict_exp512.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p7_TextCNN_train_exp_512_0609.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p7_TextCNN_predict_exp512_0609.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p7_TextCNN_train_exp.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p8_TextCNN_predict_exp.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p7_TextCNN_train_exp512.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p7_TextCNN_predict_exp.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a02_TextCNN/other_experiement/p7_TextCNN_predict_exp512_simple.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a00_boosting/a08_boosting.py:3:1: F821 undefined name 'reload'
reload(sys)
^
./a00_boosting/a08_boosting.py:21:20: F821 undefined name 'np'
    labels_predict=np.argmax(logits,axis=1) # logits:(256,108,754)
                   ^
./a00_boosting/a08_boosting.py:48:29: F821 undefined name 'np'
    weights_list_batch=list(np.ones((len(answer_list))))
                            ^
./aa6_TwoCNNTextRelation/p9_twoCNNTextRelation_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a06_Seq2seqWithAttention/a1_seq2seq_attention_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a06_Seq2seqWithAttention/a1_seq2seq_attention_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./aa4_TextCNN_with_RCNN/p72_TextCNN_with_RCNN_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a08_EntityNetwork/a3_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a08_EntityNetwork/a3_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a01_FastText/p5_fastTextB_predict_multilabel.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a01_FastText/p5_fastTextB_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./aa5_BiLstmTextRelation/p9_BiLstmTextRelation_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a03_TextRNN/p8_TextRNN_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a03_TextRNN/p8_TextRNN_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a05_HierarchicalAttentionNetwork/p1_HierarchicalAttention_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a05_HierarchicalAttentionNetwork/p1_HierarchicalAttention_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a04_TextRCNN/p71_TextRCNN_train.py:5:1: F821 undefined name 'reload'
reload(sys)
^
./a04_TextRCNN/p71_TextRCNN_predict.py:5:1: F821 undefined name 'reload'
reload(sys)
^
38    F821 undefined name 'reload'
38
@cclauss cclauss closed this as completed Nov 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant