Isn't it the court's job to decide who is and isn't actually a criminal, and to choose the appropriate punishment for them? If the court is preventing an alleged criminal from being punished in some particular way, then isn't it likely that either A) it's not the appropriate punishment, B) they're not guilty, or C) that they've have yet to have a fair trial to determine guilt and/or punishment?