Error importing otbApplication with python on Ubuntu16

For few days now, I have tried to setup the python interface for OTB. Every time I try to run “import otbApplication” from my python shell, I get the error “No module named ‘otbApplication’”.

I have successfully built and compiled the otb from the repo as seen below:
[ 98%] Performing install_copyright step for ‘OTB’
[ 98%] Completed ‘OTB’
[100%] Built target OTB

I have also made sure to set the right environment variables according to this link by putting the following in my .profile

OTB_APPLICATION_PATH="/home/oluwayetty/OTB/install/lib/otb/applications"
PYTHONPATH="/home/oluwayetty/OTB/install/lib/otb/python"

I also tried another alternative of setting the OTB_APPLICATION_PATH and PYTHONPATH in the “/home/otb/Packaging/Files/otbenv.profile” file after which I source it but it’s same error still.

I have been on this for days and it’s getting quite frustrating, not sure what to do anymore or figure out what I’m missing, searched online and couldn’t find anything useful that can help. I’ll really appreciate any insights on what else I can try. Thanks

Can you ls those paths, so we can seek what’s here ? I notice this is an install dir, did you run make install ? From you build log snippet we can not tell.

Thanks @jmichel for coming to my rescue.
Yes, I did run make from the build directory. I literally followed this article for my setup and used the SuperBuild approach. Maybe it’s an old setup and I’ve mixed things up.

What do you mean ls those paths? I’m pretty new to the LinuxOS, from a MacOs. Kindly clarify. Thanks

ls is an unix command that prints the content of the argument folder. @jmichel just wants to know if there is something in :

i.e. if OTB has been installed successfully.

As Julien said, can you try to run the make install command in your build directory (/home/oluwayetty/OTB/build/).

Oddly this is not in the SoftwareGuide …

I found out the problem was with my environment variables. For some unknown reasons, I had to reboot and everything worked fine. I didn’t change a thing.

Glad to know you are ready to go with OTB !