Machine Learning Steps
I found both of your options slightly faulty. So, this is generally (very broadly) how a predictive modelling workflow looks like:


Data Cleaning: Takes the most time, but every second spent here is worth it. The cleaner your data gets through this step, the lesser would your total time spent would be. 
Splitting the data set: The data set would be splitted into training and testing sets, which would be used for the modelling and prediction purposes respectively. In addition, an additional split as a cross-validation set would also need to be done.
Transformation and Reduction: Involves processes like transformations, mean and median scaling, etc.
Feature Selection: This can be done in a lot of ways like threshold selection, subset selection, etc.
Designing predictive model: Design the predictive model on the training data depending on the features you have at hand.
Cross Validation:
Final Prediction, Validation