How to teach a dog not to cross the street