>>>from nltk import wordnet as wn
>>>wn.synsets('dog')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'synsets'
If I use this,
>>> wn.synset('dog')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: 'module' object is not callable
This I tuk it from the tutorial. How shud I proceed..?
On Sun, May 20, 2012 at 11:58 PM, Freeda <freed...@gmail.com> wrote:
> Hi,
> I am using the follwoing:
> >>>from nltk import wordnet as wn
> >>>wn.synsets('dog')
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> AttributeError: 'module' object has no attribute 'synsets'
> If I use this,
> >>> wn.synset('dog')
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> TypeError: 'module' object is not callable
> This I tuk it from the tutorial. How shud I proceed..?
I reorganised NLTK's top level imports, and tested things as well as I
could (we're still getting our testing process fixed up, so I might have
overlooked something).
In general, if a book example doesn't work, please check that you've got
the latest version of NLTK installed, and if the problem persists, report
it via the NLTK issue tracker, or else to this list.