Your post is why there are so many dog attacks, inc a great many fatal ones.
Dogs can be unpredictable and have genetic make ups that, in certain breeds, makes them not afraid of humans at all and when they do attack, they don't stop and they are unstoppable.
I remember seeing a video of a Rottweiller attacking a person, someone hit the dog over the head with an iron bar, it made no difference, it kept going.
More recently, UK police fired 9 rounds into an XL Bully before it stopped.
Training isn't compulsory and the law allows idiots to have large aggressive and uncontrollable dogs.
This is what needs to change, the Dangerous Dogs Act needs urgent reform.