-
Notifications
You must be signed in to change notification settings - Fork 14
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
error #4
Comments
There seems to be an error in either how the masking array is being built (the shape yielded by the sentences2Index() method in Utils.py is not congruent with the shape initialized in the Decomposable model in Model.py) or how the masking array is being initialized in the first place. I've tried reshaping to get (,100) instead but there are some mask arrays that have less than 100 elements, therefore I just used a try except block to check how many erroneous ones were being produced, and another try except block on the evaluate method() in Train.py to skip the arrays that did not fit. if you have managed to solve the problem and run the full code please let me know |
Couldn't solve this problem, but found the original code that this repo may have been based from and this one works perfectly: https://github.com/cxncu001/NLI |
Returning s1MaskList and s2MaskList instead of s1Mask and s2Mask, respectively, in the sentence2Index function seems to work. |
thanks @voidcentury and @thefirebanks for great supports |
Hi
Thank you for sharing this code when I run the code I got this error
While running python3 Train.py, I am getting the following error:
Start training and evaluating ...
Epoch : 1
Traceback (most recent call last):
File "Train.py", line 164, in
train()
File "Train.py", line 93, in train
_, batch_loss, batch_acc = sess.run([model.train, model.loss, model.acc], feed_dict=feed_dict)
Traceback (most recent call last):
File "/home/nujud/Desktop/code/Decomposable-Attention-master/Train.py", line 166, in
train()
File "/home/nujud/Desktop/code/Decomposable-Attention-master/Train.py", line 95, in train
_, batch_loss, batch_acc = sess.run([model.train, model.loss, model.acc], feed_dict=feed_dict)
File "/home/nujud/anaconda2/envs/tensorflow-cpu/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 900, in run
run_metadata_ptr)
File "/home/nujud/anaconda2/envs/tensorflow-cpu/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1111, in _run
str(subfeed_t.get_shape())))
ValueError: Cannot feed value of shape (128,) for Tensor 'premise_mask:0', which has shape '(?, 100)'
please help
Thank you in advance
Looking forward for your reply.
Thanks,
The text was updated successfully, but these errors were encountered: