Beginning Anomaly Detection Using



Download 26,57 Mb.
Pdf ko'rish
bet115/283
Sana12.07.2021
Hajmi26,57 Mb.
#116397
1   ...   111   112   113   114   115   116   117   118   ...   283
Bog'liq
Beginning Anomaly Detection Using Python-Based Deep Learning

Figure 4-66.  Code to show the neural network

Figure 4-67.  Code to compile the model

Compile the model using adam as the optimizer and mean squared error for the 

loss computation. Adam is an optimization algorithm that can be used instead of the 

classical stochastic gradient descent procedure to update network weights iteratively 

based on training data. Figure 

4-67


 shows the code to compile the model.

Chapter 4   autoenCoders




172

Now, you can start training the model using the training dataset to validate the 

model at every step. Choose 32 as the batchsize and 20 epochs. The training process 

outputs the loss and accuracy as well as the validation loss and validation accuracy at 

each epoch. Figure 

4-68


 shows the code to train the model.

Figure 4-68.  Code to train the model

Chapter 4   autoenCoders




173

Now that the training process is complete, let’s evaluate the model for loss and 

accuracy. Figure 

4-69


 shows that the accuracy is 0.23. It also shows the code to evaluate 

the model.

The next step is to calculate the errors, and detect and also plot the anomalies and 

the errors. Choose a threshold of 10. Figure 

4-70

 shows the code to predict the anomalies 



based on the threshold.


Download 26,57 Mb.

Do'stlaringiz bilan baham:
1   ...   111   112   113   114   115   116   117   118   ...   283




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