Answer: You should imagine seeing the evil thoughts as good thoughts, as thoughts that lead you to the goal.
Question: But we receive our thoughts from the environment…
Answer: We receive the evil thoughts from the Creator through the environment and not from the environment itself. No object in creation affects us by itself. The Creator is always behind everything, exhibiting this “theater” to us.
From the Kabbalah Lesson in Russian 5/9/16