Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Now the challenge becomes creating a training dataset that is varied enough to ensure good generalization. To go back to the dog example, I would not want to train my model using only pictures where the dog appears in the lower left corner!
Maybe I did not phrase my question properly. Imagine an algorithm aiming to identify a given target (e.g. a dog) from a series of photos. Would it make sense to use the position of the dog in each picture as a feature?
Thanks for your answer, @Ipounng! You make a valid point: I know regularization from geophysical data inversion and it does indeed prevent overfitting by promoting a certain behavior (e.g. smoothness or "blockyness"). In that regards, you are right that constraining the model prevents it from overfitting.
Thanks for your reply, Pedro. I confirm that there is no data leakage from the bigger dataset to the training dataset. I will give k-fold cross-validation a shot!
Sorry about that! I am OK to delete either post, but I received interesting answers on both SO and the Data Science Stack Exchange and I would like to keep track of them all. What should I do?