The reality is that you night be illegally targeted and profiled based on data that is freely accessible. Robbery is illegal, yet it still makes sense to avoid behavior that can get you robbed.
It's not illegal (though unethical imho), it's the actions taken using that knowledge. Most effective if combined with parallel construction [1] that allow police to issue a trumped-up charge on a specific target.