I learn that AIC is usually used for assessing goodness of fit of a model and the criterion takes into account both goodness of fit and number of parameters used so that it could regulates the issue of overfitting.
While nowadays k-fold cross validation is commonly used for assessing model prediction performance. The two criterion should mostly align.
However recently I come across several instances in Kaggle where a model with better AIC result in worse cross validation error rate and test set error rate. While a model with worse AIC results in a better cross validated error rate and better test set error rate.
What are the reasons for such discrepency?