Closed sztal closed 1 year ago
Do you have the latest version of spacy-experimental
installed? It appears that this particular bug was fixed in v0.6.2.
Thanks! But will v0.6.2
work with spacy>=3.4,3.5
and en_coreference_web_trf(0.3.4.0a2)
(which seems to be the latest model that works out-of-the-box)?
Anyways, I will try updating to v0.6.2
soon and will let you know. Thanks once again for the fast reply!
Okay, it works! I updated successfully to spacy-experimental(0.6.3)
, while keeping spacy>=3.4,<3.5
and using en_coreference_web_trf(0.3.4.0a2)
and everything works as expected.
Thanks a lot!
interesting. encountering the same error. will try spacy experimental as well :)
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.
Problem as in the title. Code that is perfectly fine when
spacy
runs on CPU breaks when GPU acceleration is turned on. This happens at least for the model en_coreference_web_trf-3.4.0a2.How to reproduce the behaviour
So clearly the component does its job when running on CPU. But run this with
spacy.prefer_gpu()
and everything breaks:It seems that some tensors are stored on GPU and some still on CPU. Apparently this inconsistency may appear in several different parts of the code but for sure for the above reprex it is happening around line 269 of
pytorch_coref_model.py
where an attempt at performing an operation using tensorsword_ids
(stored on CPU) andtop_indices
(stored on GPU) is made.Your Environment