The dictionary definition of the word ode is
1. In early use (esp. with reference to ancient literature): a poem intended to be sung or one written in a form originally used for sung performance
2. Later: a lyric poem, typically one in the form of an address to a particular subject, written in varied or irregular metre. Also in extended use.
Traditionally, an ode (in this sense) rarely exceeded 150 lines and could be much shorter...The term is sometimes applied to certain short Old English poems, such as The Battle of Brunanburh.
I was under the impression an ode had to about something one loved but this does not seem to be true. http://www.poets.org/viewmedia.php/prmMID/5784
This site says
"The subject matter of the ode tends to be celebratory, and of a particular subject matter or personage (ode to my sister, ode on a box of crayons, &c). Keep in mind when titling your odes, that typically an ode "to" something is written as address, with second-person reference (a "You" entity and an "I" entity). An ode "on" something is more detached and written with third person reference to the subject matter."
http://www.poems-and-quotes.com/article.html?id=609
"tends to be" does not mean "has to be".
Write your teacher an essay on it!
IMO an ode should be reflective (not "has to be"). Perhaps your ode was too active - an incitement to action, or to whip up anger on the topic.
(I do however agree with midnightmoon re marijuana. )