Thanks to its role underpinning many of the recent advances in artificial intelligence, developers are increasingly interested in becoming fluent in machine learning. Notably, the number of 'massive open online courses' or MOOCs and self-learning courses in this area doubled in 2017 alone.
Here we’ll explain what it is, how you can get started plus the best tools and languages you need to develop machine learning technology.
What is machine learning?
Machine learning is a subset of artificial intelligence defined by US computing pioneer Arthur Samuel in 1959 as a ‘field of study that gives computers the ability to learn without being explicitly programmed’.
Instead, machine learning programmes are ‘trained’ on large amounts of data, in which they will begin to spot patterns or identify trends. 'Deep learning’ and ‘neural networks’ are more subsets within machine learning, which you may have heard of.
Practical examples of machine learning include speech recognition, the technology underpinning self-driving cars and web searches. Other uses involve the predictive abilities of machine learning software, for example, forecasting when machines, trains or ships will need maintenance before they break.
Why developers struggle with machine learning
Despite becoming an increasingly indispensable skill within the developer community, developers often find machine learning complex to get to grips with. This is partly because this area of programming is more mathematical than most.
While in other areas, developers can dodge directly applying mathematics thanks to a reliance on reusable functions, the application of real-life mathematics is a must within machine learning.
In fact, the basis of this area of programming is comprised of statistics, probability and linear algebra, which can prove offputting for some.
Statistical and data analysis are also important skills in this area, given that the this is the bread and butter of machine learning programmes. The ability to work with huge data sets, and effectively parse and visualise data is essential if you want to get into this area.
How to get started with machine learning
The route many tech specialists take when learning a new skill is to look for traditional training courses. However this may not be possible financially – and there are an abundance of cheaper, online options out there.
"The best way to get started is talk to experts or other competent people, and join a community of others wanting to learn," says Matt Jones, head of analytics at Tessella.
If you have a data science team within your company – go and talk to them, get mentoring and advice.
You can also head online and over to Topcoder and Kaggle, which both support vast communities of machine learning experts and run competitions where you can learn to solve specific problems, Jones advises.
There are also plenty of free online courses to choose from. Andrew Ng’s machine learning course on Coursera is one of the best, according to Raghu Ramanujan, head of data science at Twizoo.
Ramanujan also recommends two textbooks: the classic, Chris Bishop's Pattern Recognition and Machine Learning and Learning From Data by Yaser S. Abu-Mostafa, Malik Magdon-Ismail, Hsuan-
Another book worth reading is Peter Norvig’s Artificial Intelligence: A Modern Approach, according to Alex Lavin, software engineer at Numenta.
"It’s important to fundamentally understand the algorithms you’ll be using, otherwise every machine learning method is a black box and the best you can do is blindly throw them at problems... You’re going to fail, often, but that’s how to best learn machine learning techniques," he adds.
It’s also important to step back and first answer the ‘why’ before the ‘how’, according to Jones.
"The key thing to do before jumping in is really think about what you want to achieve and how you define success. It can be a business problem, a personal challenge or an interest. But once you identify that, it can really help to focus efforts and decide the next step," he explains.
Best programming languages for machine learning
"Python, without a doubt," says Lavin. "Most machine learning and data analytics toolkits are in Python and it has a huge, helpful community."
Both Jones and Ramanujan agree Python should be the go-to language for developers hoping to build machine learning platforms. It should be comfortable and familiar for most developers and means that many of them won’t need to learn a new language, says Jones.
"It’s highly readable and is easy to learn… libraries such as theano and Google’s TensorFlow that are used in bleeding edge ‘deep learning’ systems are also Python-based. You are unlikely to outgrow Python anytime soon," says Ramanujan.
Although Jones suggests it’s also worth checking out another language called ‘R’.
"R has more complete, complex and in-depth machine learning capabilities. It’s the way to go if you can. However, you aren’t pinned down to these things, these are lots of ML models that use Python," he explains.
Read next: Best online courses for machine learning
Best tools for machine learning
The tools you need depend on the problems you are trying to solve and the data you are dealing with. However, "open source reigns supreme" according to Lavin.
He recommends Scikit-Learn for its broad range of machine learning and data analytics tools, plus mlpack for C++ developers, NLTK for natural language processing methods and NuPIC for streaming analytics.
Read next: Best online courses for Python
There are various other skills you’ll need to have, according to Ramanujan: data manipulation skills, basic statistical analysis and data visualisation, for example.
To implement large big data/machine learning pipelines you also need to be familiar with a distributed computing network like Apache Spark, he says.
A number of big technology companies have released their own machine learning toolkits which are well worth tinkering with, according to Jones. As well as Google TensorFlow, there is Amazon Machine Learning, IBM Watson and Facebook’s ‘FBLearner Flow’, all of which are open source and available for free.
"That removes that barrier of having to spend a huge amount of capital to invest in AI. Once you decide what you want to do, you really want to start experimenting with which work best for your needs," he says.
How to set up a machine learning framework
Before you launch in, the first and most important step is to understand the problem you are trying to solve, according to both Lavin and Ramanujan, in order to avoid dissatisfaction and frustration further down the line.
It also involves an understanding of the relative strengths and weaknesses of the different machine learning methods described above, says Ramanujan.
There are six basic steps you need to follow when setting up a machine learning framework, Lavin says:
- Define the problem
- Analyse and prepare the data
- Select algorithms
- Run and evaluate the algorithms
- Improve the results with focused experiments
- Finalise results with fine tuning
It's crucial that you really understand the data before beginning to experiment with algorithms, because otherwise you can have no confidence in the resultant quality or reliability, he explains.
"For the algorithms that are suitable for your problem and data, there are many criteria to consider: reliability, efficiency, scalability, and so on," says Lavin. "Keep in mind any given method (e.g. deep learning) is not a hammer for every nail.
"I often see engineers are dissatisfied with their results because they immediately throw deep learning models at their data without first understanding the real problem."
Lavin offers one last tip: if you plan to share or deploy this machine learning framework, document everything you do. This will become invaluable both to you and to other engineers further down the line.
Read next: Learn to code with these UK courses