Kaggle's 30 Days Of ML (Competition Part-1): Cross Validation & First Submission on Kaggle

preview_player
Показать описание
This video is a walkthrough of Kaggle's #30DaysOfML. In this video, I will show you the very first steps needed to start with a competition: thinking about cross-validation, implmenting it and making your first submission using the cross validation folds that you created!

Note: this video is not sponsored by #Kaggle!

Please subscribe and like the video to help me keep motivated to make awesome videos like this one. :)

Follow me on:
Рекомендации по теме
Комментарии
Автор

Please subscribe and like the video to help me keep motivated to make awesome videos like this one. :)

abhishekkrthakur
Автор

I just saw your video thrice, searched for what is kfold once more. And then I was able to understand your code mostly. Since its my first time, I guess I have such a feeling. And the ones after for loop was amazing. I need some more practice to think sequentially that way. Thanks once again for the amazing tutorial.

harishchandrasekaran
Автор

Hi Abhishek, when I started reading your book AAMLP, I felt a bit confused while creating the folds. But after watching this video, everything has become crystal clear. Thanks a lot for such lucid and crisp explanation.

praveerparmar
Автор

I love those walkthrough especially in a competition like this, any more coming ?

malawad
Автор

Thanks for giving us a place to start, I was absolutely clueless on what do before this video

williamsokol
Автор

I am new to DS ML and kaggle as well and I was confused how to start with kaggle and your tutorials cleared a lot more concepts ..Thank you so much..

sumeerabhat
Автор

Damn it 20 days, and I'm seeing this now! I feel sad for missing out but I'm finally here

GIT_Somya
Автор

Great Content Mr.Abhishek, Keep up the good work

TheMISBlog
Автор

Thanks for this video. It was helpful. Please elaborate and explain a little bit more so that if we messed up with concept during these 15 days, those concepts may get cleared.

vaishnavibelsare
Автор

Thank you for this tutorial, you videos are really helpful

siddharthganjoo
Автор

You deserve millions of suscribers....

dhruvnivatia
Автор

Thanks Abhishek sir!😀 I learned a lot, this will improve my level of coding. Will follow your all upcoming videos.Thanks Again for channel!!

RaushanKumar-qbde
Автор

A thousand thanks!! Your tutorials are the best :) I will purchase your book

naylamp_gaming
Автор

Thank you for your amazing work. I'm learning alot from you

penninahgathu
Автор

Your video was very useful for me.thank you very mach for your nice explanations.

somiab
Автор

It was A little harder and thank you for the great help...

purposeoriented
Автор

Really appreciate your video, learnt a lot from it

junsenchen
Автор

I was running this following cell

final_predictions = []
for fold in range(5):
xtrain = df[df.kfold != fold].reset_index(drop=True)
xvalid = df[df.kfold == fold].reset_index(drop=True)
xtest = df_test.copy()

ytrain = xtrain.target
yvalid = xvalid.target

xtrain = xtrain[useful_features]
xvalid = xvalid[useful_features]

ordinal_encoder = OrdinalEncoder()
xtrain[object_cols] =
xvalid[object_cols] =
xtest[object_cols] =

model = XGBRegressor(random_state=fold, n_jobs=4)
model.fit(xtrain, ytrain)
preds_valid = model.predict(xvalid)
test_preds = model.predict(xtest)

print(fold, mean_squared_error(yvalid, preds_valid, squared=False))

But getting the following error

AttributeError Traceback (most recent call last)
in <module>
5 xtest = df_test.copy()
6
----> 7 ytrain = xtrain.target
8 yvalid = xvalid.target
9

in __getattr__(self, name)
5463 if
5464 return self[name]
-> 5465 return object.__getattribute__(self, name)
5466
5467 def __setattr__(self, name: str, value) -> None:

AttributeError: 'DataFrame' object has no attribute 'target'

Can't figure out what happened

adnana
Автор

@Abhishek sir, can you please create a video on pipeline especially performing feature engineering (feature interaction to create new features) through pipeline? This will be really helpful. Thank you

mithilesh
Автор

@1:56 you are saying…


….you can just simply use k-Fold, All you need to do is you have to see if the distribution of data is same in each fold if it is not use others…



I want ask how you will know by looking at histogram that the distribution of data is same in each fold?

talhaanwer