Egypt has seen a sharp rise in drive-by shootings and attacks targeting police and the military in the aftermath of the popularly backed coup last July in which the army ousted Islamist president Mohamed Morsi.