The human factor is the most unpredictable of all the things after SHTF, and it becomes difficult to prepare for when everyone has the same will to survive.
Martial law is the imposition of direct military control of normal civilian functions by a government, as a response to a temporary emergency such as invasion.
Part of the problem police forces face in this sort of case, is that officers would find themselves firing on unnamed civilians. What are they going to do?
Is our military, which is trained to fight wars, not to seal the border, going to start shooting at unarmed civilians, even if they are an invasion force?