PythonApplication Script
Mantis Issue 899, reported by sdinot, assigned to rkanavath, created: 2014-03-09
Hello,
I'm not very familiar with Python and programming but try to write a script with python to automatize a classification process.
I tried to use the python application and it works fine if i open the osgeo4w shell, enter python and the python snippets from the cookbook. But, I would like to integrate the otbApplication into a Python script file. So i would prefer not to open the shell and use python but use my script file from the editor. Is this possible? do I have to set a certain path correctly or how could this work?
Thanks, for help, Claire
1394437826 - rashadkmNot an issue at all and must be asked on users list. To answer your question, yes. See a test application in Testing/Code/Wrappers http://hg.orfeo-toolbox.org/OTB/file/ba3d7d8fb081/Testing/Code/Wrappers/Python/PythonRescaleTest.py
As seen from the CMakeLists.txt[1]. you need to update PYTHONPATH to point to otbApplication.py and ITK_AUTOLOAD_PATH to otb applications
[1] http://hg.orfeo-toolbox.org/OTB/file/ba3d7d8fb081/Testing/Code/Wrappers/Python/CMakeLists.txt