Answers.Body: <p>In many cases, a production-ready model has everything it needs to make predictions without retaining training data. For example: a linear model might only need the coefficients, a decision tree just needs rules/splits, and a neural network needs architecture and weights. The training data isn't required as all the information needed to make a prediction is incorporated into the model. </p>
  
  <p>However, some algorithms retain some or all of the training data. A support vector machine stores the points ('support vectors') closest to the <a href="https://sebastianraschka.com/faq/docs/lazy-knn.html" rel="nofollow noreferrer">separating hyperplane</a>, so that portion of the training data will be stored with the model. Further, <a href="https://nlp.stanford.edu/IR-book/html/htmledition/support-vector-machines-the-linearly-separable-case-1.html" rel="nofollow noreferrer">k-nearest neighbours</a> must evaluate all points in the dataset every time a prediction is made, and as a result the model incorporates the entire training set. </p>
  
  <p>Having said that, where possible the training data would be retained. If additional data is received, a new model can be trained on the enlarged dataset. If it is decided a different approach is required, or if there are concerns about concept drift, then it's good to have the original data still on hand. In many cases, the training data might comprise personal data or make a company's competitive advantage, so the model and the data should stay separate. </p>
  
  <p>If you'd like to see how this can work, <a href="https://keras.io/getting-started/faq/#how-can-i-save-a-keras-model" rel="nofollow noreferrer">this Keras blog post</a> has some information (note: no training data required to make predictions once a model is re-instantiated).</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-28T15:07:06.387Z
Answers.Text: ahhh Thank you so much, this makes total sense now. Quick follow up question, is this newly trained model light weight enough for an older computer to run or do you still need the power of modern day GPU etc..? also once you deploy your perfected model in to use, is it done learning? or does your model continue to fine tune itself on a slower scale?
Answers.UserDisplayName: icYou520
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-29T01:47:57.080Z
Answers.Text: @icYou520 Whether the newly trained model is small enough to run easily depends on the algorithm that was used, and to some extent on the parameter settings. Most algorithms do produce small models though. For some applications, like deep packet inspection, regular models can still be too slow however. Most models are "frozen" after training, but some can continue to learn. Transfer learning is a family of techniques for training a pre-trained model on new data.
Answers.UserDisplayName: John Doucette
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-08-28T09:39:55.577Z
Answers.LastActivityDate: 2018-08-29T10:50:54.740Z
Answers.LastEditDate: 2018-08-29T10:50:54.740Z
Answers.UserDisplayName: redhqs
Body: <p>What happens <strong>after</strong> you have used machine learning to train your model? What happens to the training data?</p>
  <p>Let's pretend it predicted correct 99.99999% of the time and you were happy with it and wanted to share it with the world. If you put in 10GB of training data, is the file you share with the world 10GB?
  If it was all trained on AWS, can people only use your service if they connect to AWS through an API?</p>
  <p>What happens to all the old training data? Does the model still need all of it to make new predictions?</p>
  
Tags: <neural-networks><machine-learning><training><datasets><training-datasets>
Title: What happens to the training data after your machine learning model has been trained?
UserDisplayName: icYou520
ThreadText: # What happens to the training data after your machine learning model has been trained?
  
  (Asked by: username_0 on 2018-08-28)
  
  What happens **after** you have used machine learning to train your model? What happens to the training data?
  
  Let's pretend it predicted correct 99.99999% of the time and you were happy with it and wanted to share it with the world. If you put in 10GB of training data, is the file you share with the world 10GB?
  If it was all trained on AWS, can people only use your service if they connect to AWS through an API?
  
  What happens to all the old training data? Does the model still need all of it to make new predictions?
  
  **Tags:** neural-networks, machine-learning, training, datasets, training-datasets
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2018-08-28. Score: 4 | Accepted answer
  
  In many cases, a production-ready model has everything it needs to make predictions without retaining training data. For example: a linear model might only need the coefficients, a decision tree just needs rules/splits, and a neural network needs architecture and weights. The training data isn't required as all the information needed to make a prediction is incorporated into the model.
  
  However, some algorithms retain some or all of the training data. A support vector machine stores the points ('support vectors') closest to the [separating hyperplane](https://sebastianraschka.com/faq/docs/lazy-knn.html), so that portion of the training data will be stored with the model. Further, [k-nearest neighbours](https://nlp.stanford.edu/IR-book/html/htmledition/support-vector-machines-the-linearly-separable-case-1.html) must evaluate all points in the dataset every time a prediction is made, and as a result the model incorporates the entire training set.
  
  Having said that, where possible the training data would be retained. If additional data is received, a new model can be trained on the enlarged dataset. If it is decided a different approach is required, or if there are concerns about concept drift, then it's good to have the original data still on hand. In many cases, the training data might comprise personal data or make a company's competitive advantage, so the model and the data should stay separate.
  
  If you'd like to see how this can work, [this Keras blog post](https://keras.io/getting-started/faq/#how-can-i-save-a-keras-model) has some information (note: no training data required to make predictions once a model is re-instantiated).
  
  > **Comments:**
  > **username_0**: ahhh Thank you so much, this makes total sense now. Quick follow up question, is this newly trained model light weight enough for an older computer to run or do you still need the power of modern day GPU etc..? also once you deploy your perfected model in to use, is it done learning? or does your model continue to fine tune itself on a slower scale?  
  > **username_2**: @icYou520 Whether the newly trained model is small enough to run easily depends on the algorithm that was used, and to some extent on the parameter settings. Most algorithms do produce small models though. For some applications, like deep packet inspection, regular models can still be too slow however. Most models are "frozen" after training, but some can continue to learn. Transfer learning is a family of techniques for training a pre-trained model on new data.  
  
  ---
  
  