Much of our population doesn't drive. Those who do drive are engaged in a dangerous activity. Driving is highly regulated and reasonably safe when people comply with the rules, are licensed and insured to undo the financial consequences of their mistakes. Clearly, pedestrians are a part of the problem. A sound enforcement program should address both groups.
Pedestrians have duties.
They must stay off of certain roads and out of specified areas. They can cross most other streets in crosswalks. Many drivers seldom or never do so. Reno, NV uses police decoy pedestrians to enforce the law for those on foot.