Skip to content
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

AssertionError: No super class method found for "_instances_from_cache_file" #58

Closed
YuchenZeng opened this issue Mar 17, 2021 · 3 comments

Comments

@YuchenZeng
Copy link

Hi,

Thank you for the excellent work. I follow the steps by setting up the environment and install all requirements exactly. I want to download the scierc dataset but have the following problem.
I ran these command exactly:

conda create --name dygiepp python=3.7
pip install -r requirements.txt
conda develop .
bash ./scripts/data/get_scierc.sh

This is the problem I have:

Traceback (most recent call last):
  File "scripts/data/shared/normalize.py", line 5, in <module>
    from dygie.data.dataset_readers.document import Document, Dataset
  File "/ldap_shared/home/v_yuchen_zeng/696ds/dygiepp-master/dygie/data/__init__.py", line 1, in <module>
    from dygie.data.dataset_readers.dygie import DyGIEReader
  File "/ldap_shared/home/v_yuchen_zeng/696ds/dygiepp-master/dygie/data/dataset_readers/dygie.py", line 29, in <module>
    class DyGIEReader(DatasetReader):
  File "/ldap_shared/home/v_yuchen_zeng/696ds/dygiepp-master/dygie/data/dataset_readers/dygie.py", line 202, in DyGIEReader
    @overrides
  File "/ldap_shared/home/v_yuchen_zeng/anaconda3/envs/dygiepp/lib/python3.7/site-packages/overrides/overrides.py", line 67, in overrides
    raise AssertionError('No super class method found for "%s"' % method.__name__)
AssertionError: No super class method found for "_instances_from_cache_file"
Traceback (most recent call last):
  File "scripts/data/shared/collate.py", line 4, in <module>
    from dygie.data.dataset_readers import document
  File "/ldap_shared/home/v_yuchen_zeng/696ds/dygiepp-master/dygie/data/__init__.py", line 1, in <module>
    from dygie.data.dataset_readers.dygie import DyGIEReader
  File "/ldap_shared/home/v_yuchen_zeng/696ds/dygiepp-master/dygie/data/dataset_readers/dygie.py", line 29, in <module>
    class DyGIEReader(DatasetReader):
  File "/ldap_shared/home/v_yuchen_zeng/696ds/dygiepp-master/dygie/data/dataset_readers/dygie.py", line 202, in DyGIEReader
    @overrides
  File "/ldap_shared/home/v_yuchen_zeng/anaconda3/envs/dygiepp/lib/python3.7/site-packages/overrides/overrides.py", line 67, in overrides
    raise AssertionError('No super class method found for "%s"' % method.__name__)
AssertionError: No super class method found for "_instances_from_cache_file"

I tried emnlp-2019 branch but I still got the same problem. Have you ever had to this problem before? Thanks!

@dwadden
Copy link
Owner

dwadden commented Mar 18, 2021

Hi Yuchen,

It's possible that AllenNLP 2.0+ breaks things. I changed requirements.txt to require allennlp==1.1.0. If things still aren't working for you, try reinstalling allennlp and allennlp_models and see if things work. If that doesn't fix it, feel free to reopen.

@JueXiuHuang
Copy link

Hi,
I got the same problem when I tried to use dygiepp training on ace05 event dataset.
For some reason (my GPU is 3080, which does not support pytorch 1.6 and allennlp 1.1.0), I need to use latest version of pytorch and allennlp, how can I solve this problem? Thanks!

@dwadden
Copy link
Owner

dwadden commented Nov 8, 2021

Unfortunately, I can only offer support using the versions of packages specified in the requirements.txt file. You could find a different GPU that is compatible, or - if you have the time - I'd also welcome a pull request that updates the code base for the latest Pytorch and AllenNLP versions.

Sorry I can't help more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants