Home:ALL Converter>'from gensim import test' is not importing successfully

'from gensim import test' is not importing successfully

Ask Time:2016-03-14T19:07:17         Author:umbreenh

Json Formatter

I installed gensim, Python library. I executed the command

Import gensim

It executed without any error. Then I tried to import test from gensim using the command

from gensim import test

and it showed the following error

Traceback (most recent call last): File "", line 1, in from gensim import test ImportError: cannot import name 'test'

Python site-packages had gensim folder in that. Any help would be highly appreciated.

Author:umbreenh,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/35985851/from-gensim-import-test-is-not-importing-successfully
Cyrbil :

As it says: cannot import name 'test'\nThat means that test is not in gensim package.\n\nYou can see package's modules with:\n\nimport gensim\nprint(gensim.__all__) # when package provide a __all__\n\n\nor\n\nimport gensim\nimport pkgutil\nmodules = pkgutil.iter_modules(gensim.__path__)\nfor module in modules:\n print(module[1])\n\n\nEdit:\n\n\n How can I verify gensim installation ?\n\n\ntry:\n import gensim\nexcept NameError:\n print('gensim is not installed')\n\n\nSide note: if you have a file or package named gensim, this will ne imported instead of the real package.",
2016-03-14T11:20:31
yy