>>> import sklearn.model_selection.train_test_split
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'sklearn.model_selection.train_test_split'
The interpreter is unable to find the train_test_split module.
>>> import sklearn.model_selection as sm
>>> sm.train_test_split
<function train_test_split at 0x000001841E8FB7B8>
But importing using as solves the issue, why? Is there any difference between import and import module as name. According to Python : 'import module' vs 'import module as' these should be same.