CI/CD and deployment strategy
1. CI/CD and deployment strategy
Good job on finishing those exercises. We will now look into CI/CD and deployment strategies.2. CI/CD pipeline
The CI/CD pipeline is also part of the deployment phase.3. CI/CD pipeline
A CI/CD is like having a list of checks to do before the launch of a new recipe in a restaurant. We can have a structured pipeline when we make a new recipe, make changes to the recipe, and check whether it is in accordance with our expected taste.4. Continuous Integration
Continuous integration is the practice where code changes are continuously integrated quickly and frequently. Each change is automatically tested when these are committed and merged. It is similar to how a new recipe is developed in a restaurant, and is tested before it is being served to guests.5. Continuous Deployment
Continuous deployment works together with continuous integration by automating the release of the code that was validated during the CI process. Continuous deployment is similar to launching a new recipe once it is tested. For instance, we put the new recipe on the menu, and explain the ingredients of the dish to people in service.6. Deployment strategies
Once a machine learning model is ready to be deployed, we can choose different deployment strategies. Each strategy has a different way of replacing the old machine learning model with the new machine learning model. We will look into three deployment strategies, namely, basic, shadow, and canary deployment.7. Deployment strategies
In a basic deployment strategy, we simply replace the old model with the new model in production. All new input data will be sent to the new model instead of the old model.8. Deployment strategies
In the shadow deployment, we send new data both to the new model, as well as to the old model. We still use the old model in production. The result of both models will be tested in order to make sure the new model works as expected.9. Deployment strategies
Using canary deployment, we use the new model in production, but only for a small part of new incoming data. In this way, we do use the new model right away, but in case the new model fails, only a small number of users is affected.10. Deployment strategies
The basic deployment is the easiest to implement and uses the least amount of resources because the new model fully replaces the old one. This does come with a high risk in case the model does not work as expected. The shadow deployment is similar in terms of implementation but uses more resources as we fully run both models instead of replacing one with the other. There is no risk when the model does not work as expected. The canary deployment is a bit harder to implement but uses fewer resources than having two fully deployed models. However, the risk is slightly higher when the new model does not work as expected.11. Let's practice!
We have now looked into the CI/CD pipeline and deployment strategies. Let's put it to the test!Create Your Free Account
or
By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.