Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
1–10 of 31 posts
Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#2As far as putting into production I'm not as familiar. Yet I hear that a good Python workflow would probably work best.
Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#3I'm a statistician by trade so I mostly do prototype work. As far as building models my key workflow is using a R and Rstudio. The biggest issue is data management. I suggest a good API or wrapper for a data source that has all of the ETL already done for the most part. R connects very well to most database systems. RStudio makes development easier with connectivity to GitHub or other popular version control systems.…
Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#4[1] https://engineering.semantics3.com/moving-machine-learning-f...
Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#5I'm a statistician by trade so I mostly do prototype work. As far as building models my key workflow is using a R and Rstudio. The biggest issue is data management. I suggest a good API or wrapper for a data source that has all of the ETL already done for the most part. R connects very well to most database systems. RStudio makes development easier with connectivity to GitHub or other popular version control systems.…
Also Rstudio mates well with bitbucket for those who want private repos for free.
Also per the production environment. The key is having the same machine learning libraries available in both the development and production so you can plug the model in with little problems with dependencies. For this reason most folks that will go into production, particularly web applications, will tend to both develop and implement in Python, Java, etc.
Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#6If your production environment has very low latency requirements you are going to have some work cut out for you. You'll most likely have to rewrite all your transformation code in a faster language like Go or Java. You might also need to implement the inference code as well to get the speed you need. This adds considerable time and adds a ton of surface error for potential insidious bugs. The ML will still make predictions, but they will be wrong or very slightly wrong.
Because I'm working with larges of amounts of data and my source of truth is Parquet logs in S3, the pipelines start with Spark. We do as much data wrangling as possible in Spark to get things into a manageable size to create our train/dev/test sets. This data gets uploaded to S3.
The datasets are then trained on EC2 instances using Pandas & sklearn. When everything is fully automated the Spark job will push a message onto an SQS queue with the S3 path of the fresh dataset. An EC2 instance will be polling that queue and pull down the data and train a new model.
The final result of training my case is a text or binary model file that goes back up to S3. Our prediction microservice polls an S3 bucket and pulls down any updated model files and swaps out the running models.
Tips:
1. Instrument everything! Hopefully you have something like graphite/datadog/prometheus in place already, but you'll want metrics on your predictions.
2. Exception tracking on everything especially anything in your model creation pipeline. Sentry or something like that.
3. Try and keep everything as simple as possible.Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#7Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#8If you use Algorithmia.com you can add your model in the language of your choice (on GPUs if you want) and it will do all of the Devops and give you an API end point. You get free credits at sign up and quite a few each month for testing.
Re: Ask HN: What's Your CI/CD Workflow for Your Machine Learning Projects?
#9[1]: https://algorithmia.com/tags/computer-vision [2]: https://algorithmia.com