问题
I integrate Python and Java with Jython but I need some libraries(pandas, numpy, skfuzzy, matplotlib, sklearn, pickle) but Jython can't support some of them.
Is it possible import that libraries from Jython or exist other Framework, language, library, something that afford a complete integrate with Python libraries.
回答1:
Unfortunately the code for packages like numpy
and scipy
includes extension modules written in languages like Fortran and C, which are specifically tailored to the CPython interpreter. That makes them incompatible with Jython, which does not support the CPython extension interface.
Probably the best you could do would be to have your Java programs use some sort of network-based communications with a locally-hosted Python server that you could write in CPython, but that might introduce unacceptable inefficiencies, depending on the necessary program structure.
来源:https://stackoverflow.com/questions/32143032/integrate-python-and-his-libraries-with-java