Even if you have never caught someone in the act, you have certainly seen pet feces on the sidewalk. Some people just don’t pick up after their dog, you can out a sign up but that doesn’t really force someone to do it. How can you force someone to do it? Guilt them beyond belief? Yes, that will work.
A man noticed a woman that passed by his house with her dog every morning and never picked up after it, so what did he do? He waited one morning, and had a megaphone and air horn with him to really get his message across. His doorbell cam captured the whole thing.
Regardless of how you feel about it, it ended up working.