Nn
该文件是TPOT库的一部分。
当前版本的TPOT是由以下人员在Cedars-Sinai开发的: - Pedro Henrique Ribeiro (https://github.com/perib, https://www.linkedin.com/in/pedro-ribeiro/) - Anil Saini (anil.saini@cshs.org) - Jose Hernandez (jgh9094@gmail.com) - Jay Moran (jay.moran@cshs.org) - Nicholas Matsumoto (nicholas.matsumoto@cshs.org) - Hyunjun Choi (hyunjun.choi@cshs.org) - Miguel E. Hernandez (miguel.e.hernandez@cshs.org) - Jason Moore (moorejh28@gmail.com)
TPOT的原始版本主要由宾夕法尼亚大学的以下人员开发: - Randal S. Olson (rso@randalolson.com) - Weixuan Fu (weixuanf@upenn.edu) - Daniel Angell (dpa34@drexel.edu) - Jason Moore (moorejh28@gmail.com) - 以及许多慷慨的开源贡献者
TPOT 是免费软件:您可以根据自由软件基金会发布的 GNU 宽通用公共许可证的条款重新分发和/或修改它,许可证的版本可以是第 3 版,或者(根据您的选择)任何以后的版本。
TPOT 的发布是希望它能有用, 但没有任何保证;甚至没有对 适销性或特定用途适用性的暗示保证。更多详情请参阅 GNU 较宽松通用公共许可证。
您应该已经收到了一份GNU较宽松通用公共许可证的副本,随TPOT一起提供。如果没有,请参见http://www.gnu.org/licenses/。
PytorchClassifier
¶
基类:PytorchEstimator, ClassifierMixin
Source code in tpot2/builtin_modules/nn.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 | |
fit(X, y)
¶
适用于将PyTorch估计器拟合到训练集的通用方法。
参数:
| 名称 | 类型 | 描述 | 默认值 |
|---|---|---|---|
X |
array-like of shape (n_samples, n_features)
|
训练向量,其中 n_samples 是样本数量,n_features 是特征数量。 |
required |
y |
array-like of shape (n_samples,)
|
相对于X的目标向量。 |
required |
返回:
| 类型 | 描述 |
|---|---|
self
|
已拟合的估计器。 |
Source code in tpot2/builtin_modules/nn.py
PytorchEstimator
¶
基类:BaseEstimator
用于TPOT的基于Pytorch的估计器(目前仅分类器)的基类。
将来,这些将被合并到TPOT的主代码库中。
Source code in tpot2/builtin_modules/nn.py
PytorchLRClassifier
¶
Logistic Regression 分类器,使用 PyTorch 实现,适用于 TPOT。
有关独立使用(即非TPOT)的示例,请参考: https://github.com/trang1618/tpot-nn/blob/master/tpot_nn/estimator_sandbox.py
Source code in tpot2/builtin_modules/nn.py
PytorchMLPClassifier
¶
多层感知器,使用PyTorch实现,用于TPOT。