Hands-On Machine Learning with Scikit-Learn and TensorFlow


| Chapter 4: Training Models



Download 26,57 Mb.
Pdf ko'rish
bet124/225
Sana16.03.2022
Hajmi26,57 Mb.
#497859
1   ...   120   121   122   123   124   125   126   127   ...   225
Bog'liq
Hands on Machine Learning with Scikit Learn Keras and TensorFlow

150 | Chapter 4: Training Models


Figure 4-24. Linear decision boundary
Just like the other linear models, Logistic Regression models can be regularized using 

1
or ℓ
2
penalties. Scitkit-Learn actually adds an ℓ
2
penalty by default.
The hyperparameter controlling the regularization strength of a
Scikit-Learn 
LogisticRegression
model is not 
alpha
(as in other
linear models), but its inverse: 
C
. The higher the value of 
C
, the 
less
the model is regularized.
Softmax Regression
The Logistic Regression model can be generalized to support multiple classes directly,
without having to train and combine multiple binary classifiers (as discussed in
Chapter 3
). This is called 
Softmax Regression
, or 
Multinomial Logistic Regression
.
The idea is quite simple: when given an instance x, the Softmax Regression model
first computes a score 
s
k
(x) for each class 
k
, then estimates the probability of each
class by applying the 
softmax function
(also called the 
normalized exponential
) to the
scores. The equation to compute 
s
k
(x) should look familiar, as it is just like the equa‐
tion for Linear Regression prediction (see 
Equation 4-19
).
Equation 4-19. Softmax score for class k
s
k
x
T
θ
k
Note that each class has its own dedicated parameter vector θ
(k)
. All these vectors are
typically stored as rows in a 
parameter matrix

Download 26,57 Mb.

Do'stlaringiz bilan baham:
1   ...   120   121   122   123   124   125   126   127   ...   225




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish