Neyon tarmoqni o’qitish paramertlarini(o’qish qadami-lr, o’qitishlar soni-epoch) tanlang




Download 0,64 Mb.
bet8/8
Sana13.05.2024
Hajmi0,64 Mb.
#230369
1   2   3   4   5   6   7   8
Bog'liq
Mashinali o\'qitish uchun chiziqli algebra. Chiziqli algebra masa

. Neyon tarmoqni o’qitish paramertlarini(o’qish qadami-lr, o’qitishlar soni-epoch) tanlang.
optimizer = Adam(learning_rate=0.001)
model.compile(optimizer, loss='categorical_crossentropy', metrics=['accuracy'])
history = model.fit(train_x, train_y, verbose=2, batch_size=5, epochs=200)


Neyron tarmoqning o’qitish natijalarini garfik tarvirlang.
Grafikda tasvirlab ko’ramiz.
plt.figure(figsize=(14,2))

plt.subplot(131)


plt.plot(history.history['accuracy'])
plt.title('Model accuracy')
plt.ylabel('Accuracy')
plt.xlabel('Epoch')
plt.grid()

plt.subplot(132)


plt.plot(history.history['loss'])
plt.title('Model loss')
plt.ylabel('Loss')
plt.xlabel('Epoch')
plt.grid()
plt.show()



Model aniqligini hisoblang(o’rgatuvchi tanalama uchun).

Modelni test to’plam bilan testlang. Modelini test to’plamdagi aniqligini hisoblang.



Download 0,64 Mb.
1   2   3   4   5   6   7   8




Download 0,64 Mb.

Bosh sahifa
Aloqalar

    Bosh sahifa



Neyon tarmoqni o’qitish paramertlarini(o’qish qadami-lr, o’qitishlar soni-epoch) tanlang

Download 0,64 Mb.