Probably every dog owner has experienced the inconvenience of having their dog bark at strangers passing by for no reason.