From Data Distributions to Regularization in Invariant Learning