jiegzhan / multi-class-text-classification-cnn

Classify Kaggle Consumer Finance Complaints into 11 classes. Build the model with CNN (Convolutional Neural Network) and Word Embeddings on Tensorflow.
Apache License 2.0
426 stars 198 forks source link

Error in training resolved #5

Open ushagayatri opened 7 years ago

ushagayatri commented 7 years ago

To switch to tensorflow 0.9 on python 3-

so now i am using python 3 and Tensorflow 0.9.

export TF_BINARY_URL=https://storage.googleapis.com/tensorflow/mac/tensorflow-0.9.0rc0-py3-none-any.whl python3 -m pip install $TF_BINARY_URL

Then at line 82 replace this - losses = tf.nn.softmax_cross_entropy_with_logits(self.scores, self.input_y) with - losses = tf.nn.softmax_cross_entropy_with_logits(labels = self.input_y, logits = self.scores) # only named arguments accepted

This worked for me! @jiegzhan , Do you agree with this?