There is a hell of a difference in context - cops are not federal agents. if a citizen brings a civil rights case against a police department they do this in a federal court - the prosecutor does not work for the same people that may be held responsible for the damage. Thats how you get consent decrees, leadership changes, etc.
Those cases can be career ending for police leadership, and career making for the prosecutors - you can figure out the incentives and deterrents that flow down to the chain.
ICE are federal agents - they are not DOJ but work closely enough, and follow the directives of the same executive branch. Unless the agencies have both disparate policies and a lot of independence (not the case today), a zealous prosecution will be damaging and embarrassing for the executive branch in general.
No prosecutor is going to touch that without clear support from the top. Agency leadership is not going to worry about that risk if they're getting the go ahead from the top of the branch. No individual agent will see the risk of "crossing the line" ending his career, or their boss and their bosses' boss.
For a lot of people those deterrents had gone too far, enforcement had their hands tied, etc. so they don't see this as a bad thing. But we have seen what happens in towns and cities when you give local police "bonuses" and incentives for aggressive enforcement without checks.