ParikhKadam / bidaf-keras

Bidirectional Attention Flow for Machine Comprehension implemented in Keras 2
GNU General Public License v3.0
64 stars 21 forks source link

Errors when theano backened is running in Linux #7

Closed hariteja97 closed 5 years ago

hariteja97 commented 5 years ago

In my lubuntu 18.04 system, the code is throwing errors when I try to train the model in CLI. and I have got the error as like this.

ERROR: Traceback (most recent call last): File "/home/hariteja/anaconda3/lib/python3.7/runpy.py", line 185, in _run_module_as_main return _run_code(code, main_globals, None,"main", mod_spec) File "/home/hariteja/anaconda3/lib/python3.7/runpy.py", line 79, in _run_code exec(code, run_globals) File "/home/hariteja/Desktop/MachineComp/bidaf/main.py", line 123, in main() File "/home/hariteja/Desktop/MachineComp/bidaf/main.py", line 81, in main encoder_dropout=args.encoder_dropout, decoder_dropout=args.decoder_dropout) File "/home/hariteja/Desktop/MachineComp/bidaf/models/bidaf.py", line 37, in init similarity_matrix = Similarity(name='similarity_layer')([encoded_passage, encoded_question]) File "/home/hariteja/anaconda3/lib/python3.7/site-packages/keras/engine/base_layer.py", line 457, in call output = self.call(inputs, **kwargs) File "/home/hariteja/Desktop/MachineComp/bidaf/layers/similarity_layer.py", line 35, in call context_dim_repeat = K.concatenate([[1, 1], [num_query_words], [1]], 0) File "/home/hariteja/anaconda3/lib/python3.7/site-packages/keras/backend/theano_backend.py", line 892, in concatenate if py_all([is_sparse(x) for x in tensors]): File "/home/hariteja/anaconda3/lib/python3.7/site-packages/keras/backend/theano_backend.py", line 892, in if py_all([is_sparse(x) for x in tensors]): File "/home/hariteja/anaconda3/lib/python3.7/site-packages/keras/backend/theano_backend.py", line 93, in is_sparse return th_sparse_module and isinstance(tensor.type, th_sparse_module.SparseType) AttributeError: 'list' object has no attribute 'type'

i tried everything for solving this issue and I have followed every steps like models in the saved_items and data and everything but still couldn't solve this issue.

Any help would be great.

hariteja97 commented 5 years ago

Please @parikhkadam kindly help me in this issue for execution

ParikhKadam commented 5 years ago

@hariteja97 I already saw this issue but the problem is, we don't have a machine to test it. You may read our README.md where we are asking for donations to buy a new setup.

Thank you..

hariteja97 commented 5 years ago

@parikhkadam ok sir thanks a lot.. when I am running in any other windows system. I'm getting warning s like

  1. Use rate instead of keep_prod..but when I executed in my system there were no errors..

  2. I was getting the error as tf. Session error in tensorflow backend when I run the same code in other machines

Kindly help me

On Tue, 21 May 2019, 20:49 Kadam Parikh, notifications@github.com wrote:

@hariteja97 https://github.com/hariteja97 I already saw this issue but the problem is, we don't have a machine to test it. You may read our README.md where we are asking for donations to buy a new setup.

Thank you..

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ParikhKadam/bidaf-keras/issues/7?email_source=notifications&email_token=AG7EBMF6QFO5RO7UNRKV6GDPWQHJJA5CNFSM4HN7IHGKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODV4IE3A#issuecomment-494436972, or mute the thread https://github.com/notifications/unsubscribe-auth/AG7EBMFQR64A7GTMPJ73VITPWQHJJANCNFSM4HN7IHGA .

ParikhKadam commented 5 years ago

@hariteja97 You can ignore warnings.. It won't effect the training. If there are any errors which makes a system exit, then post the full error trace here. You should open a new issue for new errors.

Thank you..

hariteja97 commented 5 years ago

Thanks