[SciPy-User] OT: calling Java from Python

Christoph Gohlke cgohlke@uci....
Thu Dec 23 15:00:14 CST 2010



On 12/23/2010 12:49 PM, Christopher Barker wrote:
> Hi folks,
>
> This is a bit OT, but y'all tend to be a great resource for lots of
> stuff, and this is python-for-science related:
>
> Are there any active projects supporting calling Java from CPython?
>
> It seems JPE and JPype are both pretty dead, and I don't see much else
> except maybe Babel:
>
> https://computation.llnl.gov/casc/components/#page=home
>
>    -- thought that seems kind of like yet another language!)
>
> My use case:
>
> Lately Unidata has put a lot more emphasis on the JAVA implementation of
> the netcdf libraries that the C one, so it has a lot of nifty features
> not supported for C, and therefore for Python.
>
> There is this project for calling the netcdf JAVA libs from MATLAB:
>
> http://sourceforge.net/apps/trac/njtbx
>
> Which made me think that it would be nice to have something similar for
> Python. With the Python C api and JNI (and maybe Cython), it should be
> possible, but I sure don't want to start doing that from scratch.
>
> gnu CNI looks promising, too.
>
>
> There is a lot going on in the JAVA world, it would be nice to access
> some of that.
>
> Are any of you doing anything like this? Any thoughts? There
>
>
> -Chris
>
>

CellProfiler <http://www.cellprofiler.org/> calls Java libraries 
(bioformats, ImageJ) via JNI. Take a look at 
<https://svn.broadinstitute.org/CellProfiler/trunk/CellProfiler/cellprofiler/utilities/javabridge.pyx>.

--
Christoph


More information about the SciPy-User mailing list