How to find the version of Spacy and python used in a pickle file?

Viewed 473

I want to open the following pickle file that I dumped a few months ago, but I get the following error.

dataset_s = pickle.load(open("dataset_s.pickle",'rb'))

AttributeError: Can't get attribute 'cluster' on <module 'spacy.lang.lex_attrs' from ...

Also, when I want to import the packages that I used, I get the following warning.

DeprecationWarning: `should_run_async` will not call `transform_cell` automatically in 
    the future. Please pass the result to `transformed_cell` argument and any exception 
    that happen during thetransform in `preprocessing_exc_tuple` in IPython 7.17 
    and above, and should_run_async(code)

Can someone help me resolve these issues?

1 Answers

If you are getting this file from Github, it is very likely that they have a file called requirements.txt where they describe the version requirements for packages.

Depending on the environment are you using, there are even different ways you can you can set up the environment to automatically update/reverse based on the requirements.txt:

Warning does not influence your current run, but it is best to change your code to be compatible with the future versions of the package according to it. Or you can also save the version information and reverse to older version package in the future.

Related