I want to call python from the java code and pass the parameters to function in python. I have encapsulated a function in python. But the thing is I have also imported third party library sklearn in the python program. When I call a test program and pass the value to python, I am able to run the code. But when I tried using third party library such as sklearn and import in the python code, I got following error.
ImportError: No module named sklearn
I initialized object for the class PythonInterpreter and then using the following command, I included the path for the sklearn
this.interpreter.exec("import sys");
this.interpreter.exec("sys.path.append(\"/usr/local/lib/python2.7/dist-packages/sklearn\")");
Can anyone tell how to fix this problem? How to include third party library in the jython code and run the program?