Library Search
结果页

原生类别特征 + early stopping 分类实战

在 知识库 中找到 8 个匹配结果。

返回文档库
知识库

知识库

8 个
原生类别特征 + early stopping 分类实战 # ─── 3. 训练 + Early Stopping ─── callbacks = [ lgb.early_stopping(stopping_rounds=20, verbose=1), lgb.log_evaluation(period=50), ] model = lgb.LGBMClassifier( n_estimators=500, learni… 3% XGBoost 调参心法与数学原理 # XGBoost 入门教程:调参心法与数学原理 ## 1. XGBoost 是什么? XGBoost 是基于 **梯度提升决策树 (GBDT)** 的并行优化实现。核心思想:串行训练多棵弱决策树,每棵新树拟合前一步的残差。 $$ \hat{y}_i^{(t)} = \hat{y}_i^{(t-1)} + \eta \cdot f_t(x_i) $$ 其中 $f_t$ 是第 t 棵树,$\… 2% Leaf-wise 生长与 GOSS 原理揭秘 ## 5. 原生类别特征:不用 One-Hot! ```python # ❌ XGBoost 需要这样(特征膨胀!) pd.get_dummies(df, columns=['city']) # ✅ LightGBM 原生支持 df['city'] = df['city'].astype('category') model.fit(X, y, categorical_feature=['cit… 2% NLTK 与 NLP 基础:语料库、语法树与分类器 ```python grammar = nltk.CFG.fromstring(""" S -> NP VP NP -> Det N | Det N PP | 'I' VP -> V NP | VP PP PP -> P NP Det -> 'the' | 'a' N -> 'dog' | 'cat' | 'park' V -> 'saw'… 2% 核心原理深入教程 @Component @Scope(value = "request", proxyMode = ScopedProxyMode.TARGET_CLASS) public class RequestScopedBean { } // Web 环境,每次 HTTP 请求 @Component @Scope(value = "session", proxyMode = ScopedProxyMod… 2% 入门教程 - 企业级框架核心概念 deleteProduct(id: number): Observable<void> { return this.http.delete<void>(`/api/products/${id}`); } } ``` ## 九、最佳实践 1. **使用 Standalone Components**(Angular 15+),告别 NgModule 样板 2. **Signals 优… 2% 鸢尾花分类:训练 + 交叉验证 + 特征重要性 # ─── 5. 特征重要性 ─── xgb.plot_importance(model, importance_type="gain") plt.title("XGBoost Feature Importance (Gain)") plt.tight_layout() plt.savefig("feature_importance.png") plt.show() print("\n特征重要性… 1% Hello World 与 LINQ 入门 // 辅助方法 static string GetGrade(double score) => score switch { >= 90 => "A", >= 80 => "B", >= 70 => "C", >= 60 => "D", _ => "F" }; static async Task FetchDataAsync() { Console… 1%