AttributeError: module '01_parse' has no attribute 'path'

Hi all,

The sense2vec module uses the pathlib library, but that somehow doesn't work.

directory ~/Documents/Sense2Vec
ls: all_text.txt sense2vec_data.txt Data sense2vec-master FastText pycache

command: :~/Documents/Sense2Vec$ python -m all_text.txt ./Data en_core_web_sm

response: /usr/bin/python3: Error while finding module specification for '' (AttributeError: module '01_parse' has no attribute 'path')

I use python 3.6, and did a fresh install of the pathlib library

There should be a simple solution....


I don't think this is related to pathlib, which is a module built into the standard library. I think it's because you're trying to execute a Python file as a module by running python -m, which won't work. There's no need to use -m here, you just want to execute the file using python

This is embarrassing...

thanks, it works.