Leader localization in multi-agent systems subject to failure: A graph-theoretic approach