Closed AndriyMulyar closed 3 years ago
Thanks for the report! That does look suspicious. Usually the nO
dimension should be set by initializing the model with example input & output, so that it can infer the dimensions, but this may not work with the Torch
encoder. You could be right that we need to set it specifically. I'll have a look!
This issue was a bit more involved than I had initially hoped, but I think https://github.com/explosion/spaCy/pull/6442 and https://github.com/explosion/thinc/pull/432 together should fix this. At least the training now runs for me when I replicate your config.
Thanks again for the detailed report!
[EDIT: it works when I set
[EDIT 2: Never mind the above, it works with static vectors as well when setting e.g. include_static_vectors
to False
and fails with a different error otherwise, but that's another issue that I'm looking into]vectors = "en_core_web_lg"
]
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
I get the following error when attempting to use the BiLSTM encoder with the NER transition based parser:
Could the pytorch BiLSTM wrapper encoder perhaps be missing a line like this (which appears in the CNN encoders): https://github.com/explosion/spaCy/blob/dc816bba9d564ae572af28a17cbf0580ba11db5e/spacy/ml/models/tok2vec.py#L274
https://github.com/explosion/spaCy/blob/dc816bba9d564ae572af28a17cbf0580ba11db5e/spacy/ml/models/tok2vec.py#L302
Also the docstring is not accurate (seems to be copied from the CNNs)
My model components look like this: