Why data scientists should start learning Swift

Swift for TensorFlow and the future of machine learning development.

One week into my first year physics course at the University of Michigan, a professor assigned a problem set that required simulating some many-body system. It was due Friday. That was the week I learned my first programming language, Matlab.

This is how I’ve picked up bits and pieces of a dozen or so languages over the past decade. Besides an introductory CS class taught with C++ and a Java-based database class in graduate school, I never had any formal training in software engineering. For me, coding was a way to finish my homework, analyze data to answer a question, or turn an idea in my head into something real.

Sometimes this meant familiarizing myself with the details of algorithms or data structures, but I never found myself coding for the sake of coding. I don’t have an opinion on generics (don’t @ me). I think this describes the vast majority of data scientists and machine learning engineers I know. When it comes to choosing tools, we’re often optimizing for usability and efficiency within the context of the problems we want to solve, not software fundamentals.

Fast forward to 2018, and the machine learning and data science community seems to have settled on Python. The syntax is beginner friendly, it’s a great scripting language, and when you’re looking to optimize performance, you can interface with lower level libraries in C.

For me, though, the most appealing part of Python is that it’s a “good enough” language for building entire systems end-to-end. The Scientific computing packages like Numpy, Pandas, Matplotlib, and Jupyter notebooks have huge community support. And when it’s time to build an application around your work, frameworks like Flask and Django are performant enough to scale to hundreds of millions of users. I can build an entire system using a single programming language.

I’ve been satisfied with Python for almost 10 years. But I don’t think I’ll still be using it another decade from now. I think I’ll be using Swift.