Menu

#3 lexnames not found on XP WordNet 2.1

open
nobody
None
5
2005-03-29
2005-03-29
Anonymous
No

Here is the error that I get when I try some of the
examples.
I went into the wordnet.py file and changed the path to
WordNet\\2.1, but the lexnames file isn't in the dict
directory.

I'm on an XP machine. Python 2.3, WordNet 2.1

>>> from wordnet import *
Traceback (most recent call last):
File "<pyshell#0>", line 1, in -toplevel-
from wordnet import *
File "C:\Python23\lib\site-packages\wordnet.py", line
802, in -toplevel-
setupLexnames()
File "C:\Python23\lib\site-packages\wordnet.py", line
798, in setupLexnames
for l in open(WNSEARCHDIR+'\\lexnames').readlines():
IOError: [Errno 2] No such file or directory:
'C:\\Program Files\\WordNet\\2.1\\dict\\lexnames'
>>>

Discussion

  • Nobody/Anonymous

    Logged In: NO

    doesn't work on linux neither. I think PyWordNet is ment to
    work for WordNet 2.0 only. lexnames seems to be quite
    useless also.

     
  • Nobody/Anonymous

    Logged In: NO

    I have the same problem:

    [userid@host pywordnet-2.0.1]$ python
    Python 2.4.2 (#1, Nov 20 2005, 13:03:38)
    [GCC 3.3.1 (Mandrake Linux 9.2 3.3.1-2mdk)] on linux2
    Type "help", "copyright", "credits" or "license" for more
    information.
    >>> from wordnet import *
    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "wordnet.py", line 768, in ?
    setupLexnames()
    File "wordnet.py", line 764, in setupLexnames
    for l in open(WNSEARCHDIR+'/lexnames').readlines():
    IOError: [Errno 2] No such file or directory:
    '/scratch/userid/usr/local/bin/dict/lexnames'
    >>>

    Is this package still maintained at all?

    antonyliu2002@yahoo.com

     
  • Nobody/Anonymous

    Logged In: NO

    "Natural Language Toolkit has taken over the development of pywordnet. There is now a Python package, nltk_lite.wordnet, which incorporates pywordnet and which supports WordNet 2.1. It is included in NLTK Lite. "
    http://wordnet.princeton.edu/links#Python

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.