Re: JCC Install

2009-02-23 Thread Andi Vajda
On Sun, 22 Feb 2009, Andi Vajda wrote: Thank you for the patch. This is the second time in a week that someone suggest the same thing: a variable to specify the JDK root (JAVA_HOME or somesuch). I'll take the ideas from both patches and incorporate that into JCC's setup.py. I added a 'JDK'

Re: how to instantiate a Set?

2009-02-23 Thread Andi Vajda
On Sun, 22 Feb 2009, Andi Vajda wrote: On Sun, 22 Feb 2009, Bill Janssen wrote: I'm probably missing something incredibly obvious here... I'm trying to call MoreLikethis.setStopWords(Set words). I've got a list of stop words in Python, but I can't figure out how to turn that into a Java Se

Re: how to instantiate a Set?

2009-02-23 Thread Andi Vajda
On Sun, 22 Feb 2009, Bill Janssen wrote: OK, I added JavaSet to my codebase. You can now use the one in the PyLucene's collections module: >>> from lucene.collections import JavaSet But still no joy -- I can now call mlt = MoreLikeThis(...) mlt.setStopWords(JavaSet(set(["foo", "b

Re: how to instantiate a Set?

2009-02-23 Thread Bill Janssen
>>> a = JavaSet(set(['foo', 'bar', 'baz'])) How about letting me initialize JavaSet with a sequence, too? >>> a = JavaSet(['foo', 'bar', 'baz']) Bill

Re: how to instantiate a Set?

2009-02-23 Thread Bill Janssen
Andi Vajda wrote: > On Sun, 22 Feb 2009, Bill Janssen wrote: > > > OK, I added JavaSet to my codebase. > > You can now use the one in the PyLucene's collections module: > >>>> from lucene.collections import JavaSet > > > But still no joy -- I can now call > > > >mlt = MoreLikeThis(...

Re: how to instantiate a Set?

2009-02-23 Thread Bill Janssen
Bill Janssen wrote: > OK, I added JavaSet to my codebase. > > But still no joy -- I can now call > > mlt = MoreLikeThis(...) > mlt.setStopWords(JavaSet(set(["foo", "bar", "bletch"]))) > terms = mlt.retrieveInterestingTerms(...) > > Unfortunately, I still get "foo", "bar", and "blet

Re: how to instantiate a Set?

2009-02-23 Thread Andi Vajda
On Feb 23, 2009, at 8:42, Bill Janssen wrote: a = JavaSet(set(['foo', 'bar', 'baz'])) How about letting me initialize JavaSet with a sequence, too? a = JavaSet(['foo', 'bar', 'baz']) Well, sure, but the point of JavaSet is to expose a set you own and control to Java. If you want to

Re: how to instantiate a Set?

2009-02-23 Thread Andi Vajda
On Feb 23, 2009, at 8:56, Bill Janssen wrote: Bill Janssen wrote: OK, I added JavaSet to my codebase. But still no joy -- I can now call mlt = MoreLikeThis(...) mlt.setStopWords(JavaSet(set(["foo", "bar", "bletch"]))) terms = mlt.retrieveInterestingTerms(...) Unfortunately, I st

Re: JCC Install

2009-02-23 Thread Jacob Floyd
> > I added a 'JDK' dict variable to setup.py that contains the root of the jdk > installation for each platform. I then replaced all hard coded occurrences > of that directory in the INCLUDES and LFLAGS dicts. > If a JCC_JDK env variable is set it supercedes the value in setup.py for > your platfo

Re: JCC Install

2009-02-23 Thread Andi Vajda
On Feb 23, 2009, at 10:06, Jacob Floyd wrote: I added a 'JDK' dict variable to setup.py that contains the root of the jdk installation for each platform. I then replaced all hard coded occurrences of that directory in the INCLUDES and LFLAGS dicts. If a JCC_JDK env variable is set it sup