मॉडल ट्यूनिंग

Python में Machine Learning के साथ CTR प्रेडिक्शन

Kevin Huo

Instructor

Regularization

नीली और हरी रेखा वाला रेग्युलराइज़ेशन उदाहरण

  • Regularization: मॉडल में पैरामीटर के कोएफिशिएंट्स के मान बदलकर overfitting कम करना।
  • Regularization से परफॉर्मेंस मैट्रिक्स बेहतर हो सकते हैं और ad spend का ROI बढ़ सकता है।
Python में Machine Learning के साथ CTR प्रेडिक्शन

Regularization के उदाहरण

  • Logistic Regression: C पैरामीटर regularization strength का इनवर्स है।
  • कम से ज़्यादा complex: C=0.05 < C=0.5 < C=1
  • Decision Tree: max_depth पेड़ की अधिकतम गहराई नियंत्रित करता है।
  • कम से ज़्यादा complex: max_depth=3 < max_depth=5 < max_depth=10
Python में Machine Learning के साथ CTR प्रेडिक्शन

Cross validation

K-fold क्रॉस वैलिडेशन

  • k folds में, हर fold को testing set (validation) के रूप में लें, और बाकी k-1 को training के लिए।
  • इस तरह मॉडल परफॉर्मेंस के k evaluations मिलते हैं।
  • ध्यान दें, अलग evaluation testing set फिर भी रहता है।
Python में Machine Learning के साथ CTR प्रेडिक्शन

Cross validation के उदाहरण

k_fold = KFold(n_splits = 4, random_state = 0, shuffle = True)
for i in [3, 5, 10]:
  clf = DecisionTreeClassifier(max_depth = i)
  cv_precision = cross_val_score(
    clf, X_train, y_train, cv = k_fold, 
    scoring = 'precision_weighted')
  • Scoring strings: precision_weighted, recall_weighted, roc_auc
Python में Machine Learning के साथ CTR प्रेडिक्शन

अभ्यास करते हैं!

Python में Machine Learning के साथ CTR प्रेडिक्शन

Preparing Video For Download...