attardi / deepnl

Deep Learning for Natural Language Processing
GNU General Public License v3.0
458 stars 116 forks source link

hidden_weights dot function prototype incompatible #5

Closed kiran-surya closed 9 years ago

kiran-surya commented 9 years ago

Facing this issue with latest code.

Creating new network... ... with the following parameters:

Input layer size: 400
Hidden layer size: 300
Output size: 17

Starting training with 22138 sentences Training for up to 40 epochs Traceback (most recent call last): File "bin/dl-ner.py", line 331, in main() File "bin/dl-ner.py", line 314, in main args.threads) File "deepnl/trainer.pyx", line 123, in deepnl.trainer.Trainer.train (deepnl/trainer.cpp:3526) self._train_epoch(examples, outcomes) File "deepnl/trainer.pyx", line 341, in deepnl.trainer.TaggerTrainer._train_epoch (deepnl/trainer.cpp:8359) scores = self.tagger._tag_sequence(sent, True) File "deepnl/tagger.pyx", line 72, in deepnl.tagger.Tagger._tag_sequence (deepnl/tagger.cpp:3605) cpdef np.ndarray[FLOAT_t,ndim=2] _tag_sequence(self, File "deepnl/tagger.pyx", line 124, in deepnl.tagger.Tagger._tag_sequence (deepnl/tagger.cpp:3439) nn.forward(vars) File "deepnl/network.pyx", line 210, in deepnl.network.Network.forward (deepnl/network.cpp:6406) cpdef forward(self, Variables vars): File "deepnl/network.pyx", line 215, in deepnl.network.Network.forward (deepnl/network.cpp:6255) self.p.hidden_weights.dot(vars.input, vars.hidden) TypeError: function takes exactly 1 argument (2 given)

kiran-surya commented 9 years ago

Even with 1.3.3 version this issue is present.

attardi commented 9 years ago

You need numpy version 1.9. This is now mentioned in the requirements.