I believe that "Encourage" suggests an amount of active communication between the person encouraging, and the person being encouraged. You could say any of the following sentences:
"My teacher encouraged me to learn these words."
"I encouraged my son to work hard."
"He encouraged the runners to reach the finish line."
But you should NOT say:
"The painting encouraged my interest in art."
Inspiration is a bit less concrete. A person can inspire you, or even objects, or videos, or beautiful music. It does not usually suggest direct communication, or talking, between what is inspiring and the person being inspired.
So you can say:
"The painting inspired my interest in art."
"My friend's work with animals inspired me to volunteer at an animal shelter."
"Celine Dion inspired me to learn how to sing."