Machine learning emerged as a technique by which a computer can learn from data, without using a complex set of different rules. This approach is mainly based on training a model from datasets. The better the quality of the datasets, the better the accuracy of the machine learning model:

By Brylie Christopher Oxley - Own work, Wikimedia, CC0
A basic machine learning workflow involves all the steps illustrated in the preceding diagram. Also, the following flowchart describes the role of a machine learning algorithm in the practice of machine learning techniques. Both training and test data greatly influence a hypothesis, which can be further improved through performance-driven feedback to the same machine learning algorithm. The end result further strengthens the hypothesis:

By Jinapattanah - Own work, CC BY-SA 3.0, https://commons...