Re: Can't get iterator in the C API

2022-02-09 Thread Jen Kris via Python-list
Thank you for clarifying that.  Now on to getting the iterator from the method.  Jen Feb 8, 2022, 18:10 by pyt...@mrabarnett.plus.com: > On 2022-02-09 01:12, Jen Kris via Python-list wrote: > >> I am using the Python C API to load the Gutenberg corpus from the nltk >> library and iterate thr

Re: Can't get iterator in the C API

2022-02-08 Thread MRAB
On 2022-02-09 01:12, Jen Kris via Python-list wrote: I am using the Python C API to load the Gutenberg corpus from the nltk library and iterate through the sentences.  The Python code I am trying to replicate is: from nltk.corpus import gutenberg for i, fileid in enumerate(gutenberg.fileids()):

Can't get iterator in the C API

2022-02-08 Thread Jen Kris via Python-list
I am using the Python C API to load the Gutenberg corpus from the nltk library and iterate through the sentences.  The Python code I am trying to replicate is: from nltk.corpus import gutenberg for i, fileid in enumerate(gutenberg.fileids()):     sentences = gutenberg.sents(fileid)     et