Py3.7 problem with AP demo
Opened this issue · 1 comments
colinallen commented
User reports a problem with prep phase of demo
$ topicexplorer demo
Downloading demo-data/ap.tgz
100% [......................................................] 2925653 / 2925653
Parsing ap/ap.txt
Extracting documents to ap folder
Building corpus from ap with corpus_from_files function
100%|#########################################################################|
Saving corpus as /Users/<userdir>/Desktop/Projects/NLP/topicexplorer/models/ap.npz
Writing configuration file ap.ini
Traceback (most recent call last):
File "/Users/<userdir>//anaconda3/bin/topicexplorer", line 10, in <module>
sys.exit(main())
File "/Users/<userdir>//Desktop/Projects/NLP/topicexplorer/topicexplorer/__main__.py", line 261, in main
benchmark(demo.main)(args)
File "/Users/<userdir>//Desktop/Projects/NLP/topicexplorer/topicexplorer/demo.py", line 86, in main
prep.main(args)
File "/Users/<userdir>//Desktop/Projects/NLP/topicexplorer/topicexplorer/prep.py", line 466, in main
c = Corpus.load(args.corpus_path)
File "/Users/<userdir>//anaconda3/lib/python3.7/site-packages/vsm/corpus/base.py", line 646, in load
return Corpus._serial_load(file, load_corpus=load_corpus)
File "/Users/<userdir>//anaconda3/lib/python3.7/site-packages/vsm/corpus/base.py", line 711, in _serial_load
c.words = arrays_in['words']
File "/Users/<userdir>//anaconda3/lib/python3.7/site-packages/numpy/lib/npyio.py", line 262, in __getitem__
pickle_kwargs=self.pickle_kwargs)
File "/Users/katelynmorrison/anaconda3/lib/python3.7/site-packages/numpy/lib/format.py", line 696, in read_array
raise ValueError("Object arrays cannot be loaded when "
ValueError: Object arrays cannot be loaded when allow_pickle=False
colinallen commented
Current options here are either to downgrade numpy to 1.16.2 with
pip install numpy==1.16.2
or downgrade anaconda installation to 3.6.
More permanent fix needed, however.