{"id":499042,"date":"2026-10-17T12:25:56","date_gmt":"2026-10-17T09:25:56","guid":{"rendered":"https:\/\/savepearlharbor.com\/?p=499042"},"modified":"2026-10-17T12:25:56","modified_gmt":"2026-10-17T09:25:56","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=499042","title":{"rendered":"\u041a\u0430\u043a \u044f \u0441\u043e\u0431\u0440\u0430\u043b \u043c\u043e\u0434\u0435\u043b\u044c \u0434\u043b\u044f \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0441\u0442\u0430\u0434\u0438\u0438 \u0434\u0438\u0430\u0431\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0440\u0435\u0442\u0438\u043d\u043e\u043f\u0430\u0442\u0438\u0438 \u043d\u0430 \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u043e\u043c Colab"},"content":{"rendered":"<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p><strong>\u041f\u0440\u0435\u0434\u044b\u0441\u0442\u043e\u0440\u0438\u044f<\/strong><\/p>\n<p>\u042f \u0441\u043e\u0431\u0440\u0430\u043b \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c: \u043e\u043d\u0430 \u0441\u043c\u043e\u0442\u0440\u0438\u0442 \u043d\u0430 \u0441\u043d\u0438\u043c\u043e\u043a \u0433\u043b\u0430\u0437\u043d\u043e\u0433\u043e \u0434\u043d\u0430 \u0438 \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u0438 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0430. \u041d\u0430 \u043e\u0442\u043b\u043e\u0436\u0435\u043d\u043d\u043e\u043c \u0442\u0435\u0441\u0442\u0435 \u043f\u0435\u0440\u0432\u044b\u0439 \u0437\u0430\u043f\u0443\u0441\u043a \u0434\u0430\u043b QWK 0.834. \u041f\u043e\u0442\u043e\u043c \u044f \u0441\u0442\u0430\u043b \u0440\u0430\u0437\u0431\u0438\u0440\u0430\u0442\u044c\u0441\u044f, \u0437\u0430 \u0441\u0447\u0451\u0442 \u0447\u0435\u0433\u043e, \u0438 \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0432 \u043c\u043e\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u043e\u0442\u0432\u0435\u0442. \u042f \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0442\u0440\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c\u043d\u044b\u0445 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u043e\u0431\u0443\u0447\u0438\u043b \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c. \u0423 \u043d\u0435\u0451 QWK 0.713. \u041d\u0438\u0436\u0435 \u0432\u0435\u0441\u044c \u043f\u0430\u0439\u043f\u043b\u0430\u0439\u043d \u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u0442\u0430\u043a\u0430\u044f \u0443\u0442\u0435\u0447\u043a\u0430 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f.<\/p>\n<h3>\u0410\u043d\u0430\u043b\u0438\u0437<\/h3>\n<p>\u0412 RetinaMNIST \u0435\u0441\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u043d\u0438\u043c\u043a\u0438, \u0430\u043d\u0430\u043b\u0438\u0437\u043e\u0432 \u0442\u0430\u043c \u043d\u0435\u0442. \u042f \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0438\u0445 \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435, \u0432 \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0432\u0445\u043e\u0434\u0438\u043b\u0430 \u0438\u0441\u0442\u0438\u043d\u043d\u0430\u044f \u0441\u0442\u0430\u0434\u0438\u044f \u0431\u043e\u043b\u0435\u0437\u043d\u0438, \u0438 \u0441\u0435\u0442\u044c \u043d\u0430\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0447\u0438\u0442\u0430\u0442\u044c \u044d\u0442\u0443 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0443. \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u043d\u0430 \u0442\u0435\u0441\u0442\u0435 \u0438\u0437 400 \u0441\u043d\u0438\u043c\u043a\u043e\u0432:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"left\">\u041c\u043e\u0434\u0435\u043b\u044c<\/p>\n<\/th>\n<th>\n<p align=\"left\">QWK<\/p>\n<\/th>\n<th>\n<p align=\"left\">Macro AUC<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">\u041b\u043e\u0433\u0438\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u0438\u043d\u0442\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c, \u0431\u0435\u0437 \u0441\u043d\u0438\u043c\u043a\u0430<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.8163<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.8823<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">\u0414\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c, \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0441 \u0443\u0442\u0435\u0447\u043a\u043e\u0439<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.8340<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.8588<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">\u0414\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c \u0441 \u043e\u0431\u043d\u0443\u043b\u0451\u043d\u043d\u044b\u043c \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u043c \u0432\u0445\u043e\u0434\u043e\u043c (\u043d\u0435\u0432\u0435\u0440\u043d\u044b\u0439 baseline)<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.4502<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.7774<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">EfficientNet-B2, \u043e\u0431\u0443\u0447\u0435\u043d\u043d\u044b\u0439 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 \u0441\u043d\u0438\u043c\u043a\u0430\u0445<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.7129<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.8070<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u0420\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f, \u043d\u0435 \u0432\u0438\u0434\u0435\u0432\u0448\u0430\u044f \u043d\u0438 \u043e\u0434\u043d\u043e\u0433\u043e \u043f\u0438\u043a\u0441\u0435\u043b\u044f, \u043f\u043e\u0447\u0442\u0438 \u0434\u043e\u0433\u043e\u043d\u044f\u0435\u0442 \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u0441\u0435\u0442\u044c \u043f\u043e QWK \u0438 \u043e\u0431\u0433\u043e\u043d\u044f\u0435\u0442 \u0435\u0451 \u043f\u043e AUC. \u041f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c \u043c\u043e\u0434\u0435\u043b\u044c \u043d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u0434\u0430\u0451\u0442 QWK \u043e\u043a\u043e\u043b\u043e 0.71.<\/p>\n<h3>\u0417\u0430\u0447\u0435\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u043f\u043e\u0442\u043e\u043a<\/h3>\n<p>\u0412\u0440\u0430\u0447 \u043d\u0435 \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u0442 \u0441\u043d\u0438\u043c\u043e\u043a \u0432 \u043e\u0442\u0440\u044b\u0432\u0435 \u043e\u0442 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0430: \u043e\u043d \u0441\u043c\u043e\u0442\u0440\u0438\u0442 \u043d\u0430 \u0433\u043b\u0438\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0433\u0435\u043c\u043e\u0433\u043b\u043e\u0431\u0438\u043d (HbA1c), \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430, \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u0435. \u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0444\u0443\u043d\u0434\u0443\u0441-\u043a\u0430\u043c\u0435\u0440\u044b \u0434\u0430\u044e\u0442 \u043d\u0435\u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u0443\u044e \u0437\u0430\u0441\u0432\u0435\u0442\u043a\u0443, \u0430 \u0431\u0435\u0437 \u043a\u0430\u0440\u0442\u044b \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u043d\u0435\u043f\u043e\u043d\u044f\u0442\u043d\u043e, \u043d\u0430 \u0447\u0442\u043e \u043e\u0442\u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043b\u0430 \u0441\u0435\u0442\u044c: \u043d\u0430 \u044d\u043a\u0441\u0441\u0443\u0434\u0430\u0442 \u0438\u043b\u0438 \u043d\u0430 \u043f\u044b\u043b\u0438\u043d\u043a\u0443 \u043d\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0438\u0432\u0435. \u041e\u0442\u0441\u044e\u0434\u0430 \u043f\u043b\u0430\u043d: \u043f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0434\u0447\u0451\u0440\u043a\u0438\u0432\u0430\u0435\u0442 \u0441\u043e\u0441\u0443\u0434\u044b \u0438 \u043e\u0447\u0430\u0433\u0438, \u0432\u0442\u043e\u0440\u043e\u0439 \u0432\u0445\u043e\u0434 \u0434\u043b\u044f \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0438 Grad-CAM \u0434\u043b\u044f \u043e\u0431\u044a\u044f\u0441\u043d\u0435\u043d\u0438\u044f.<\/p>\n<p>\u0421\u0430\u043c \u043f\u043b\u0430\u043d \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439. \u041f\u043e\u0434\u0432\u0435\u043b\u0438 \u0434\u0430\u043d\u043d\u044b\u0435, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u044f \u0435\u0433\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u043b.<\/p>\n<h3>\u0414\u0430\u043d\u043d\u044b\u0435<\/h3>\n<p>\u042f \u0432\u0437\u044f\u043b RetinaMNIST \u0438\u0437 MedMNIST: 1600 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 \u0433\u043b\u0430\u0437\u043d\u043e\u0433\u043e \u0434\u043d\u0430 \u0438\u0437 \u0441\u043e\u0440\u0435\u0432\u043d\u043e\u0432\u0430\u043d\u0438\u044f DeepDRiD, \u043f\u044f\u0442\u044c \u0441\u0442\u0430\u0434\u0438\u0439 \u043f\u043e \u0448\u043a\u0430\u043b\u0435 ICDR, \u0432\u0435\u0440\u0441\u0438\u044f 224\u00d7224 \u0441 \u0433\u043e\u0442\u043e\u0432\u044b\u043c\u0438 \u0441\u043f\u043b\u0438\u0442\u0430\u043c\u0438.<\/p>\n<ul>\n<li>\n<p>DR 0: \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0440\u0435\u0442\u0438\u043d\u043e\u043f\u0430\u0442\u0438\u0438 \u043d\u0435\u0442<\/p>\n<\/li>\n<li>\n<p>DR 1: \u043b\u0451\u0433\u043a\u0430\u044f \u043d\u0435\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f<\/p>\n<\/li>\n<li>\n<p>DR 2: \u0443\u043c\u0435\u0440\u0435\u043d\u043d\u0430\u044f \u043d\u0435\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f<\/p>\n<\/li>\n<li>\n<p>DR 3: \u0442\u044f\u0436\u0451\u043b\u0430\u044f \u043d\u0435\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f<\/p>\n<\/li>\n<li>\n<p>DR 4: \u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f<\/p>\n<\/li>\n<\/ul>\n<p>\u0421\u043f\u043b\u0438\u0442\u044b: train 1080, validation 120, test 400. \u041a\u043b\u0430\u0441\u0441\u044b \u043d\u0435\u0441\u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u044b: \u0432 \u0442\u0435\u0441\u0442\u0435 174 \u0441\u043d\u0438\u043c\u043a\u0430 DR 0 \u0438 \u0432\u0441\u0435\u0433\u043e 20 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 DR 4.<\/p>\n<pre><code>pythonfrom medmnist import RetinaMNISTtrain_data = RetinaMNIST(split=\"train\", download=True, size=224)val_data   = RetinaMNIST(split=\"val\",   download=True, size=224)test_data  = RetinaMNIST(split=\"test\",  download=True, size=224)<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper\"><\/span><\/a><\/div><\/pre>\n<p><code><strong>from<\/strong> medmnist <strong>import<\/strong> RetinaMNIST  train_data = RetinaMNIST(split=\"train\", download=True, size=224) val_data   = RetinaMNIST(split=\"val\",   download=True, size=224) test_data  = RetinaMNIST(split=\"test\",  download=True, size=224)<\/code><\/p>\n<p>\u0412 \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435 \u043f\u0435\u0440\u0435\u0434 \u044d\u0442\u0438\u043c \u0441\u0442\u043e\u0438\u0442 \u043f\u043e\u043f\u044b\u0442\u043a\u0430 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c APTOS 2019 \u0447\u0435\u0440\u0435\u0437 kagglehub. \u0412 \u043c\u043e\u0451\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u043e\u043d\u0430 \u043d\u0435 \u0441\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u0430, \u043a\u043e\u0434 \u043f\u0435\u0440\u0435\u0448\u0451\u043b \u043d\u0430 RetinaMNIST, \u0438 \u0432\u0441\u0435 \u0446\u0438\u0444\u0440\u044b \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u044b \u043d\u0430 \u043d\u0451\u043c.<\/p>\n<h3>\u041f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433: \u0411\u0435\u043d \u0413\u0440\u044d\u043c \u0438 CLAHE<\/h3>\n<p>\u0427\u0442\u043e\u0431\u044b \u0443\u0431\u0440\u0430\u0442\u044c \u043d\u0435\u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u0443\u044e \u0437\u0430\u0441\u0432\u0435\u0442\u043a\u0443, \u0438\u0437 \u0441\u043d\u0438\u043c\u043a\u0430 \u0432\u044b\u0447\u0438\u0442\u0430\u0435\u0442\u0441\u044f \u0435\u0433\u043e \u0436\u0435 \u043a\u043e\u043f\u0438\u044f, \u0440\u0430\u0437\u043c\u044b\u0442\u0430\u044f \u0433\u0430\u0443\u0441\u0441\u043e\u0432\u044b\u043c \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u043c. \u042d\u0442\u043e\u0442 \u043f\u0440\u0438\u0451\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u043f\u043e\u0431\u0435\u0434\u0438\u0442\u0435\u043b\u044c \u0441\u043e\u0440\u0435\u0432\u043d\u043e\u0432\u0430\u043d\u0438\u044f Kaggle Diabetic Retinopathy Detection:<\/p>\n<pre><code>textI_enh = 4 * I - 4 * G_sigma(I) + 128<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p><code>I_enh = 4 <em> I - 4 <\/em> G_sigma(I) + 128<\/code><\/p>\n<p>\u041f\u043b\u0430\u0432\u043d\u044b\u0439 \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442 \u044f\u0440\u043a\u043e\u0441\u0442\u0438 \u0443\u0445\u043e\u0434\u0438\u0442, \u0430 \u0441\u043e\u0441\u0443\u0434\u044b, \u0433\u0435\u043c\u043e\u0440\u0440\u0430\u0433\u0438\u0438 \u0438 \u044d\u043a\u0441\u0441\u0443\u0434\u0430\u0442\u044b \u043e\u0441\u0442\u0430\u044e\u0442\u0441\u044f. \u041f\u043e\u0442\u043e\u043c CLAHE \u043f\u043e \u043a\u0430\u043d\u0430\u043b\u0443 \u044f\u0440\u043a\u043e\u0441\u0442\u0438 \u0432 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 LAB:<\/p>\n<pre><code>pythondef apply_ben_graham_preprocessing(image_np, size=224, sigmaX=10):    img = cv2.resize(image_np, (size, size))    mask = np.zeros((size, size), dtype=np.uint8)    cv2.circle(mask, (size \/\/ 2, size \/\/ 2), int(size * 0.46), 255, -1)    blurred = cv2.GaussianBlur(img, (0, 0), sigmaX)    enhanced = cv2.addWeighted(img, 4, blurred, -4, 128)    lab = cv2.cvtColor(enhanced, cv2.COLOR_RGB2LAB)    l, a, b = cv2.split(lab)    clahe = cv2.createCLAHE(clipLimit=2.0, tileGridSize=(8, 8))    l = clahe.apply(l)    enhanced = cv2.cvtColor(cv2.merge((l, a, b)), cv2.COLOR_LAB2RGB)    return cv2.bitwise_and(enhanced, enhanced, mask=mask)<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/47\/13\/98\/471398e6e7bf8625cdf2c795f3c43e22.PNG\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1 - \u041d\u0430\u0433\u043b\u044f\u0434\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1 - \u041d\u0430\u0433\u043b\u044f\u0434\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440\" width=\"1135\" height=\"498\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/47\/13\/98\/471398e6e7bf8625cdf2c795f3c43e22.PNG 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/47\/13\/98\/471398e6e7bf8625cdf2c795f3c43e22.PNG 781w\" loading=\"lazy\" decode=\"async\"\/><\/p>\n<div><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1 &#8212; \u041d\u0430\u0433\u043b\u044f\u0434\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440<\/figcaption><\/div>\n<\/figure>\n<p>\u041d\u0430 \u0441\u0442\u0430\u0434\u0438\u044f\u0445 DR 2\u20134 \u043f\u043e\u0441\u043b\u0435 \u0444\u0438\u043b\u044c\u0442\u0440\u0430 \u043d\u0430 \u0441\u0435\u0440\u043e\u043c \u0444\u043e\u043d\u0435 \u0432\u0438\u0434\u043d\u044b \u0442\u0451\u043c\u043d\u044b\u0435 \u043a\u0440\u043e\u0432\u043e\u0438\u0437\u043b\u0438\u044f\u043d\u0438\u044f \u0438 \u0441\u0432\u0435\u0442\u043b\u044b\u0435 \u043e\u0447\u0430\u0433\u0438 \u044d\u043a\u0441\u0441\u0443\u0434\u0430\u0446\u0438\u0438.<\/p>\n<h3>\u041f\u0435\u0440\u0432\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f: \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c<\/h3>\n<p>\u0412\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u044b\u0439 \u044d\u043d\u043a\u043e\u0434\u0435\u0440 \u2014 <code>efficientnet_b2<\/code> \u0438\u0437 timm. \u0422\u0430\u0431\u043b\u0438\u0447\u043d\u0430\u044f \u0432\u0435\u0442\u043a\u0430 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0438\u0442 \u0447\u0435\u0442\u044b\u0440\u0435 \u043d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044f (HbA1c, \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430, \u0441\u0438\u0441\u0442\u043e\u043b\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u0435, \u0432\u043e\u0437\u0440\u0430\u0441\u0442) \u0432 32-\u043c\u0435\u0440\u043d\u044b\u0439 \u0432\u0435\u043a\u0442\u043e\u0440. \u041f\u0435\u0440\u0435\u0434 \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u043e\u043c \u0432\u0435\u043a\u0442\u043e\u0440 \u0441\u043d\u0438\u043c\u043a\u0430 (1408 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432) \u0441\u043a\u043b\u0435\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u043c, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f 1440. \u041d\u0430 <code>conv_head<\/code> \u043f\u043e\u0432\u0435\u0448\u0435\u043d\u044b \u0445\u0443\u043a\u0438 \u0434\u043b\u044f Grad-CAM, \u0432 \u043b\u0438\u0441\u0442\u0438\u043d\u0433\u0435 \u043d\u0438\u0436\u0435 \u044f \u0438\u0445 \u043e\u043f\u0443\u0441\u0442\u0438\u043b.<\/p>\n<pre><code>pythonclass RetinaTwoStreamNet(nn.Module):    def __init__(self, backbone_name=\"efficientnet_b2\", num_classes=5, tabular_dim=4):        super().__init__()        self.backbone = timm.create_model(backbone_name, pretrained=True,                                          num_classes=0, global_pool=\"\")        vision_dim = self.backbone.num_features  # 1408        self.pool = nn.AdaptiveAvgPool2d(1)        self.tabular_net = nn.Sequential(            nn.Linear(tabular_dim, 32), nn.BatchNorm1d(32), nn.SiLU(),            nn.Dropout(0.2), nn.Linear(32, 32), nn.SiLU()        )        self.classifier = nn.Sequential(            nn.Linear(vision_dim + 32, 256), nn.BatchNorm1d(256), nn.SiLU(),            nn.Dropout(0.35), nn.Linear(256, num_classes)        )    def forward(self, img_tensor, tab_tensor):        v_emb = self.pool(self.backbone(img_tensor)).flatten(1)        t_emb = self.tabular_net(tab_tensor)        return self.classifier(torch.cat([v_emb, t_emb], dim=1))<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>\u041e\u0431\u0443\u0447\u0435\u043d\u0438\u0435: \u0432\u0435\u0441\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u043e\u0431\u0440\u0430\u0442\u043d\u043e \u043f\u0440\u043e\u043f\u043e\u0440\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b \u0438\u0445 \u0447\u0430\u0441\u0442\u043e\u0442\u0435 \u0432 train, <code>label_smoothing=0.05<\/code>, AdamW \u0441 \u0440\u0430\u0437\u0434\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0448\u0430\u0433\u0430\u043c\u0438 (\u0431\u044d\u043a\u0431\u043e\u043d 3e-4, \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u0430\u044f \u0432\u0435\u0442\u043a\u0430 \u0438 \u0433\u043e\u043b\u043e\u0432\u0430 1.2e-3), \u043a\u043e\u0441\u0438\u043d\u0443\u0441\u043d\u043e\u0435 \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435, AMP FP16, \u0430\u0443\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Albumentations (\u043f\u043e\u0432\u043e\u0440\u043e\u0442\u044b \u0434\u043e 180\u00b0, \u0444\u043b\u0438\u043f\u044b, \u044f\u0440\u043a\u043e\u0441\u0442\u044c \u0438 \u043a\u043e\u043d\u0442\u0440\u0430\u0441\u0442). 12 \u044d\u043f\u043e\u0445 \u043d\u0430 Tesla T4 \u0437\u0430\u043d\u044f\u043b\u0438 184.9 \u0441\u0435\u043a\u0443\u043d\u0434\u044b. \u041b\u0443\u0447\u0448\u0438\u0439 \u0447\u0435\u043a\u043f\u043e\u0438\u043d\u0442 \u0432\u044b\u0431\u0440\u0430\u043d \u043f\u043e \u0432\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u043c\u0443 QWK: 0.8844 \u043d\u0430 10-\u0439 \u044d\u043f\u043e\u0445\u0435.<\/p>\n<p>\u041d\u0430 \u0442\u0435\u0441\u0442\u0435: QWK 0.8340, Macro AUC 0.8588, accuracy 0.6325.<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/f0\/4a\/dd\/f04add3909017afc488c8caa748c7182.PNG\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2 - \u041c\u0435\u0442\u0440\u0438\u043a\u0438\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2 - \u041c\u0435\u0442\u0440\u0438\u043a\u0438\" width=\"1306\" height=\"465\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/f0\/4a\/dd\/f04add3909017afc488c8caa748c7182.PNG 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/f0\/4a\/dd\/f04add3909017afc488c8caa748c7182.PNG 781w\" loading=\"lazy\" decode=\"async\"\/><\/p>\n<div><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2 &#8212; \u041c\u0435\u0442\u0440\u0438\u043a\u0438<\/figcaption><\/div>\n<\/figure>\n<p>.<\/p>\n<h3>\u0427\u0442\u043e \u043d\u0435 \u0441\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c<\/h3>\n<p>\u0427\u0435\u0442\u044b\u0440\u0435 \u0447\u0438\u0441\u043b\u0430 \u043d\u0430 \u0432\u0445\u043e\u0434\u0435 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0438 \u0434\u0430\u0432\u0430\u043b\u0438 \u0441\u0435\u0442\u0438 \u0431\u043e\u043b\u044c\u0448\u0435, \u0447\u0435\u043c 1408 \u0432\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432. \u041a\u043e\u0433\u0434\u0430 \u044f \u043e\u0431\u043d\u0443\u043b\u044f\u043b \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u0439 \u0432\u0445\u043e\u0434, QWK \u043f\u0430\u0434\u0430\u043b \u0441 0.83 \u0434\u043e 0.45. \u0412 \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u0439 \u043a\u043b\u0438\u043d\u0438\u043a\u0435 HbA1c \u0438 \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430 \u0441\u0432\u044f\u0437\u0430\u043d\u044b \u0441 \u0440\u0438\u0441\u043a\u043e\u043c \u0440\u0435\u0442\u0438\u043d\u043e\u043f\u0430\u0442\u0438\u0438, \u043d\u043e \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0441\u0442\u0430\u0434\u0438\u044e \u043f\u043e \u043d\u0438\u043c \u043d\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c: \u043e\u043d\u0430 \u0432\u0438\u0434\u043d\u0430 \u043d\u0430 \u0441\u043d\u0438\u043c\u043a\u0435. \u0421\u0442\u043e\u043b\u044c \u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0432\u043a\u043b\u0430\u0434 \u0447\u0435\u0442\u044b\u0440\u0451\u0445 \u0447\u0438\u0441\u0435\u043b \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b \u0441\u0442\u0440\u0430\u043d\u043d\u043e, \u0438 \u044f \u0432\u0435\u0440\u043d\u0443\u043b\u0441\u044f \u043a \u0442\u043e\u043c\u0443, \u043a\u0430\u043a \u044d\u0442\u0438 \u0447\u0438\u0441\u043b\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u044b.<\/p>\n<h3>\u041e\u0442\u043a\u0443\u0434\u0430 \u0432\u0437\u044f\u043b\u0438\u0441\u044c \u00ab\u0430\u043d\u0430\u043b\u0438\u0437\u044b\u00bb<\/h3>\n<p>\u041a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 RetinaMNIST \u043d\u0435\u0442, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0430\u0442\u0430\u0441\u0435\u0442 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0438\u0445 \u0441\u0430\u043c:<\/p>\n<pre><code>pythondef _sample_clinical_ehr(self, stage, idx):    rng = np.random if self.is_train else np.random.RandomState(idx + 5000)    hba1c    = np.clip(5.9 + stage * 0.85 + rng.normal(0, 1.15), 4.5, 14.5)    duration = np.clip(2.5 + stage * 3.1  + rng.normal(0, 3.8),  0.0, 35.0)    sys_bp   = np.clip(122 + stage * 6.5  + rng.normal(0, 12.0), 90.0, 200.0)    age      = np.clip(46 + stage * 3.5   + rng.normal(0, 9.5),  20.0, 88.0)    return torch.tensor([(hba1c - 6.0) \/ 5.0, duration \/ 20.0,                         (sys_bp - 120.0) \/ 40.0, (age - 50.0) \/ 25.0])<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p>\u041d\u0430 \u0432\u0445\u043e\u0434 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043f\u043e\u0434\u0430\u0451\u0442\u0441\u044f <code>stage<\/code>, \u0442\u043e \u0435\u0441\u0442\u044c \u0438\u0441\u0442\u0438\u043d\u043d\u0430\u044f \u043c\u0435\u0442\u043a\u0430, \u0430 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u044e\u0442\u0441\u044f \u0438\u0437 \u043d\u0435\u0451 \u043b\u0438\u043d\u0435\u0439\u043d\u043e \u0441 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u0433\u0430\u0443\u0441\u0441\u043e\u0432\u0430 \u0448\u0443\u043c\u0430. \u042f \u0445\u043e\u0442\u0435\u043b \u00ab\u0440\u0435\u0430\u043b\u0438\u0441\u0442\u0438\u0447\u043d\u0443\u044e \u043a\u043e\u0440\u0440\u0435\u043b\u044f\u0446\u0438\u044e \u0441\u043e \u0441\u0442\u0430\u0434\u0438\u0435\u0439\u00bb, \u0430 \u043f\u043e\u043b\u0443\u0447\u0438\u043b \u0443\u0442\u0435\u0447\u043a\u0443 \u043c\u0435\u0442\u043a\u0438. \u041f\u0440\u0438\u0447\u0451\u043c \u043d\u0430 \u0442\u0435\u0441\u0442\u0435 \u0442\u043e\u0436\u0435: \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0441\u0442\u0440\u043e\u044f\u0442\u0441\u044f \u043f\u043e \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u043c \u043c\u0435\u0442\u043a\u0430\u043c. \u0421\u0435\u0442\u0438 \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0443\u0447\u0438\u0442\u044c\u0441\u044f \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0443, \u0435\u0439 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0447\u0435\u0442\u044b\u0440\u0435 \u0447\u0438\u0441\u043b\u0430.<\/p>\n<p>\u041d\u0430 train \u0448\u0443\u043c \u043a \u0442\u043e\u043c\u0443 \u0436\u0435 \u043f\u0435\u0440\u0435\u0441\u044d\u043c\u043f\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u043a\u0430\u0436\u0434\u043e\u043c \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u0438 \u043a \u043f\u0440\u0438\u043c\u0435\u0440\u0443, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0442\u0430\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 <code>np.random<\/code>. \u041f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f \u0430\u0443\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432, \u0438 \u0441\u0435\u0442\u044c \u0443\u0447\u0438\u0442\u0441\u044f \u0432\u044b\u0442\u0430\u0441\u043a\u0438\u0432\u0430\u0442\u044c \u0441\u0442\u0430\u0434\u0438\u044e \u0438\u0437 \u043b\u044e\u0431\u043e\u0439 \u0437\u0430\u0448\u0443\u043c\u043b\u0451\u043d\u043d\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0438.<\/p>\n<h3>\u0422\u0440\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c\u043d\u044b\u0445 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430<\/h3>\n<h3>1. \u041b\u043e\u0433\u0438\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u0438\u043d\u0442\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c<\/h3>\n<p>\u0415\u0441\u043b\u0438 \u0441\u043d\u0438\u043c\u043e\u043a \u043d\u0435 \u043d\u0443\u0436\u0435\u043d, \u043c\u043e\u0434\u0435\u043b\u044c \u0431\u0435\u0437 \u0441\u043d\u0438\u043c\u043a\u0430 \u0434\u043e\u043b\u0436\u043d\u0430 \u0434\u0430\u0442\u044c \u0441\u043e\u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043c\u044b\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442. \u041f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u043f\u043e \u0442\u0435\u043c \u0436\u0435 \u0444\u043e\u0440\u043c\u0443\u043b\u0430\u043c, \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u0441 \u0442\u0435\u043c\u0438 \u0436\u0435 \u0441\u0438\u0434\u0430\u043c\u0438 <code>idx + 5000<\/code>:<\/p>\n<pre><code>pythonclf_leak = LogisticRegression(max_iter=500)clf_leak.fit(X_tab_train, y_train)leak_preds = clf_leak.predict(X_tab_test)leak_probs = clf_leak.predict_proba(X_tab_test)leak_qwk = cohen_kappa_score(y_test, leak_preds, weights=\"quadratic\")leak_auc = roc_auc_score(y_test, leak_probs, multi_class=\"ovr\", average=\"macro\")<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p><code>clf_leak = LogisticRegression(max_iter=500) clf_<\/code><a href=\"http:\/\/leak.fit\" rel=\"noopener nofollow\"><code>leak.fit<\/code><\/a><code>(X_tab_train, y_train) leak_preds = clf_leak.predict(X_tab_test) leak_probs = clf_leak.predict_proba(X_tab_test)  leak_qwk = cohen_kappa_score(y_test, leak_preds, weights=\"quadratic\") leak_auc = roc_auc_score(y_test, leak_probs, multi_class=\"ovr\", average=\"macro\")<\/code><\/p>\n<p>QWK 0.8163, Macro AUC 0.8823. \u041b\u0438\u043d\u0435\u0439\u043d\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u043f\u043e \u0447\u0435\u0442\u044b\u0440\u0451\u043c \u0447\u0438\u0441\u043b\u0430\u043c \u043f\u043e\u0447\u0442\u0438 \u0440\u0430\u0432\u043d\u0430 \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u043f\u043e QWK \u0438 \u0432\u044b\u0448\u0435 \u043d\u0435\u0451 \u043f\u043e AUC. \u0414\u0440\u0443\u0433\u0438\u0445 \u0434\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c\u0441\u0442\u0432 \u0443\u0442\u0435\u0447\u043a\u0438 \u0443\u0436\u0435 \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f.<\/p>\n<h3>2. \u041e\u0431\u043d\u0443\u043b\u0435\u043d\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u043e\u0433\u043e \u0432\u0445\u043e\u0434\u0430<\/h3>\n<p>QWK 0.4502, AUC 0.7774. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u044f \u0441\u0447\u0438\u0442\u0430\u043b \u044d\u0442\u043e \u00ab\u043a\u0430\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0431\u0435\u0437 \u0430\u043d\u0430\u043b\u0438\u0437\u043e\u0432\u00bb, \u0438 \u044d\u0442\u043e \u0431\u044b\u043b\u0430 \u043e\u0448\u0438\u0431\u043a\u0430. \u041c\u043e\u0434\u0435\u043b\u044c \u043e\u0431\u0443\u0447\u0430\u043b\u0430\u0441\u044c \u0441 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u043c \u0432\u0445\u043e\u0434\u043e\u043c, \u0438 \u043d\u0443\u043b\u0435\u0432\u043e\u0439 \u0432\u0435\u043a\u0442\u043e\u0440 \u0434\u043b\u044f \u043d\u0435\u0451 \u2014 \u0432\u0445\u043e\u0434 \u0438\u0437 \u0434\u0440\u0443\u0433\u043e\u0433\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f. \u0422\u0430\u043a \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u043e\u043c\u0430\u043d\u043d\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c, \u0430 \u043d\u0435 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u043e \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c.<\/p>\n<h3>3. \u041e\u0442\u0434\u0435\u043b\u044c\u043d\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c<\/h3>\n<p>\u041f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 baseline: \u0442\u043e\u0442 \u0436\u0435 <code>efficientnet_b2<\/code> \u0441 \u0432\u0435\u0441\u0430\u043c\u0438 ImageNet, \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u0430\u044f \u0433\u043e\u043b\u043e\u0432\u0430 timm (\u043f\u0443\u043b\u0438\u043d\u0433 \u0438 \u043b\u0438\u043d\u0435\u0439\u043d\u044b\u0439 \u0441\u043b\u043e\u0439), \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0438 \u043d\u0435\u0442. \u041f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433, \u0430\u0443\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438, \u0432\u0435\u0441\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0438 <code>label_smoothing<\/code> \u0442\u0435 \u0436\u0435, \u043d\u043e learning rate \u043e\u0434\u0438\u043d, 3e-4, \u0441 \u043a\u043e\u0441\u0438\u043d\u0443\u0441\u043d\u044b\u043c \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435\u043c \u043d\u0430 12 \u044d\u043f\u043e\u0445.<\/p>\n<pre><code>pythonclass HonestVisionOnlyNet(nn.Module):    def __init__(self, backbone_name=\"efficientnet_b2\", num_classes=5):        super().__init__()        self.backbone = timm.create_model(backbone_name, pretrained=True,                                          num_classes=num_classes)    def forward(self, img_tensor):        return self.backbone(img_tensor)optimizer = torch.optim.AdamW(honest_model.parameters(), lr=3e-4, weight_decay=1e-2)scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, T_max=12)criterion = nn.CrossEntropyLoss(weight=class_weights, label_smoothing=0.05)<\/code><div class=\"code-explainer\"><a href=\"https:\/\/sourcecraft.dev\/\" class=\"tm-button code-explainer__link\" style=\"visibility: hidden;\"><span class=\"sc-logo-wrapper icon-only\"><\/span><\/a><\/div><\/pre>\n<p><code><strong>class<\/strong> HonestVisionOnlyNet(nn.Module):     <strong>def<\/strong> <strong>init<\/strong>(self, backbone_name=\"efficientnet_b2\", num_classes=5):         super().__init__()         self.backbone = timm.create_model(backbone_name, pretrained=True,                                           num_classes=num_classes)      <strong>def<\/strong> forward(self, img_tensor):         <strong>return<\/strong> self.backbone(img_tensor)  optimizer = torch.optim.AdamW(honest_model.parameters(), lr=3e-4, weight_decay=1e-2) scheduler = <\/code><a href=\"http:\/\/torch.optim.lr\" rel=\"noopener nofollow\"><code>torch.optim.lr<\/code><\/a><code>_scheduler.CosineAnnealingLR(optimizer, T_max=12) criterion = nn.CrossEntropyLoss(weight=class_weights, label_smoothing=0.05)<\/code><\/p>\n<p>\u041e\u0431\u0443\u0447\u0435\u043d\u0438\u0435 \u0437\u0430\u043d\u044f\u043b\u043e 199.1 \u0441\u0435\u043a\u0443\u043d\u0434\u044b. \u041b\u0443\u0447\u0448\u0438\u0439 \u0432\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 QWK 0.7555, \u043d\u0430 \u0442\u0435\u0441\u0442\u0435 QWK 0.7129, Macro AUC 0.8070, accuracy 0.5775.<\/p>\n<h3>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u043c\u043e\u0434\u0435\u043b\u0438 \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c<\/h3>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"left\">\u0421\u0442\u0430\u0434\u0438\u044f<\/p>\n<\/th>\n<th>\n<p align=\"left\">Precision<\/p>\n<\/th>\n<th>\n<p align=\"left\">Recall<\/p>\n<\/th>\n<th>\n<p align=\"left\">F1<\/p>\n<\/th>\n<th>\n<p align=\"left\">Support<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">DR 0 (\u043d\u043e\u0440\u043c\u0430)<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.8456<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.7241<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.7802<\/p>\n<\/td>\n<td>\n<p align=\"left\">174<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">DR 1 (\u043b\u0451\u0433\u043a\u0430\u044f)<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.2933<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.4783<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.3636<\/p>\n<\/td>\n<td>\n<p align=\"left\">46<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">DR 2 (\u0443\u043c\u0435\u0440\u0435\u043d\u043d\u0430\u044f)<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.4444<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.3913<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.4162<\/p>\n<\/td>\n<td>\n<p align=\"left\">92<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">DR 3 (\u0442\u044f\u0436\u0451\u043b\u0430\u044f)<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.6349<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.5882<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.6107<\/p>\n<\/td>\n<td>\n<p align=\"left\">68<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"left\">DR 4 (\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f)<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.2188<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.3500<\/p>\n<\/td>\n<td>\n<p align=\"left\">0.2692<\/p>\n<\/td>\n<td>\n<p align=\"left\">20<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Macro F1 0.4880, weighted F1 0.5942.<\/p>\n<figure class=\"full-width \"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/extt\/e8\/7e\/5d\/e87e5d6302cb7ed7e89709ad1686633a.png\" alt=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3 - \u041d\u043e\u0432\u044b\u0439 \u043c\u0435\u0442\u0440\u0438\u043a\u0438\" title=\"\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3 - \u041d\u043e\u0432\u044b\u0439 \u043c\u0435\u0442\u0440\u0438\u043a\u0438\" width=\"1610\" height=\"446\" sizes=\"auto, (max-width: 780px) 100vw, 50vw\" srcset=\"https:\/\/habrastorage.org\/r\/w780\/extt\/e8\/7e\/5d\/e87e5d6302cb7ed7e89709ad1686633a.png 780w,&#10;       https:\/\/habrastorage.org\/r\/w1560\/extt\/e8\/7e\/5d\/e87e5d6302cb7ed7e89709ad1686633a.png 781w\" loading=\"lazy\" decode=\"async\"\/><\/p>\n<div><figcaption>\u0420\u0438\u0441\u0443\u043d\u043e\u043a 3 &#8212; \u041d\u043e\u0432\u044b\u0439 \u043c\u0435\u0442\u0440\u0438\u043a\u0438<\/figcaption><\/div>\n<\/figure>\n<p>\u041d\u043e\u0440\u043c\u0443 \u0438 \u0442\u044f\u0436\u0451\u043b\u0443\u044e \u0441\u0442\u0430\u0434\u0438\u044e \u0441\u0435\u0442\u044c \u0440\u0430\u0437\u043b\u0438\u0447\u0430\u0435\u0442 \u0441\u043d\u043e\u0441\u043d\u043e. \u0425\u0443\u0436\u0435 \u0432\u0441\u0435\u0433\u043e \u0441 \u043f\u043e\u0433\u0440\u0430\u043d\u0438\u0447\u043d\u044b\u043c\u0438 \u0438 \u0440\u0435\u0434\u043a\u0438\u043c\u0438 \u0441\u0442\u0430\u0434\u0438\u044f\u043c\u0438: F1 \u0443 DR 1 \u0432\u0441\u0435\u0433\u043e 0.36, \u0443 DR 4 \u043e\u043a\u043e\u043b\u043e 0.27. \u041d\u0430 224\u00d7224 \u043c\u0438\u043a\u0440\u043e\u0430\u043d\u0435\u0432\u0440\u0438\u0437\u043c\u0430 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439, \u0442\u0430\u043a \u0447\u0442\u043e \u043c\u043d\u043e\u0433\u043e\u0433\u043e \u0437\u0434\u0435\u0441\u044c \u0436\u0434\u0430\u0442\u044c \u043d\u0435 \u0441\u0442\u043e\u0438\u0442.<\/p>\n<p>\u0414\u043b\u044f \u043e\u0440\u0438\u0435\u043d\u0442\u0438\u0440\u0430: \u0432 \u0431\u0435\u043d\u0447\u043c\u0430\u0440\u043a\u0435 MedMNIST+ \u043d\u0430 RetinaMNIST 224\u00d7224 \u043f\u0440\u0438 \u043f\u043e\u043b\u043d\u043e\u043c \u0434\u043e\u043e\u0431\u0443\u0447\u0435\u043d\u0438\u0438 ResNet-18 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 accuracy 61.5% \u0438 AUC 0.832, EfficientNet-B4 \u2014 52.4% \u0438 0.738, \u043b\u0443\u0447\u0448\u0438\u0439 \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0435 VGG16 \u2014 64.2% \u0438 0.878 (\u0441\u0440\u0435\u0434\u043d\u0435\u0435 \u043f\u043e \u0442\u0440\u0451\u043c \u0441\u0438\u0434\u0430\u043c). QWK \u0430\u0432\u0442\u043e\u0440\u044b \u043d\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u044f\u0442, \u0430 \u043a\u0430\u043a \u0443\u0441\u0440\u0435\u0434\u043d\u0451\u043d AUC, \u043d\u0435 \u0443\u0442\u043e\u0447\u043d\u044f\u044e\u0442, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435 \u043f\u0440\u0438\u0431\u043b\u0438\u0437\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435. \u041c\u043e\u0438 57.75% \u0438 0.807 \u043f\u043e\u043f\u0430\u0434\u0430\u044e\u0442 \u0432 \u044d\u0442\u043e\u0442 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d, \u043d\u0435 \u0432\u044b\u0448\u0435.<\/p>\n<h3>\u0427\u0442\u043e \u0438\u0437 \u044d\u0442\u043e\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c, \u0430 \u0447\u0442\u043e \u043d\u0435\u043b\u044c\u0437\u044f<\/h3>\n<p>\u041d\u0435\u043b\u044c\u0437\u044f \u043f\u0438\u0441\u0430\u0442\u044c, \u0447\u0442\u043e \u0430\u043d\u0430\u043b\u0438\u0437\u044b \u00ab\u0434\u043e\u0431\u0430\u0432\u0438\u043b\u0438 0.12 \u043a QWK\u00bb. \u0420\u0430\u0437\u043d\u0438\u0446\u0430 \u043c\u0435\u0436\u0434\u0443 0.834 \u0438 0.713 \u2014 \u044d\u0442\u043e \u0440\u0430\u0437\u043c\u0435\u0440 \u0443\u0442\u0435\u0447\u043a\u0438: \u043c\u043e\u0434\u0435\u043b\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0443, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u044f \u0441\u0430\u043c \u0437\u0430\u043b\u043e\u0436\u0438\u043b \u0432 \u0434\u0430\u043d\u043d\u044b\u0435. \u041f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u0447\u0442\u043e \u043f\u043e AUC \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c (0.8588) \u0443\u0441\u0442\u0443\u043f\u0430\u0435\u0442 \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u0438 \u043f\u043e \u0447\u0435\u0442\u044b\u0440\u0451\u043c \u0447\u0438\u0441\u043b\u0430\u043c (0.8823): \u043f\u0440\u0438 \u043d\u0430\u043b\u0438\u0447\u0438\u0438 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0438 \u0441\u043d\u0438\u043c\u043e\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u043c\u0435\u0448\u0430\u043b.<\/p>\n<p>\u041c\u043e\u0436\u043d\u043e \u043f\u0438\u0441\u0430\u0442\u044c, \u0447\u0442\u043e \u043d\u0430 \u044d\u0442\u043e\u043c \u0434\u0430\u0442\u0430\u0441\u0435\u0442\u0435 EfficientNet-B2 \u0441 \u043f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433\u043e\u043c \u0411\u0435\u043d\u0430 \u0413\u0440\u044d\u043c\u0430 \u0434\u0430\u0451\u0442 QWK \u043e\u043a\u043e\u043b\u043e 0.71 \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c.<\/p>\n<h3>\u041e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430<\/h3>\n<ul>\n<li>\n<p>\u041a\u0430\u0436\u0434\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u043e\u0431\u0443\u0447\u0435\u043d\u0430 \u043e\u0434\u0438\u043d \u0440\u0430\u0437, \u0441\u0438\u0434\u044b PyTorch \u043d\u0435 \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u044b. \u0414\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c \u043e\u0431\u0443\u0447\u0430\u043b\u0430\u0441\u044c \u0432 \u0434\u0440\u0443\u0433\u043e\u0439 \u044f\u0447\u0435\u0439\u043a\u0435 \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0430, \u0438 \u0435\u0451 \u0446\u0438\u0444\u0440\u044b \u0432\u043f\u0438\u0441\u0430\u043d\u044b \u0432 \u0441\u0432\u043e\u0434\u043d\u0443\u044e \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u0432\u0440\u0443\u0447\u043d\u0443\u044e.<\/p>\n<\/li>\n<li>\n<p>\u0412\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u044f \u0438\u0437 120 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 \u043e\u0447\u0435\u043d\u044c \u0448\u0443\u043c\u043d\u0430\u044f: \u0432\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 QWK \u0447\u0435\u0441\u0442\u043d\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438 \u0441\u043a\u0430\u0447\u0435\u0442 \u043f\u043e \u044d\u043f\u043e\u0445\u0430\u043c \u043e\u0442 0.60 \u0434\u043e 0.76, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432\u044b\u0431\u043e\u0440 \u043b\u0443\u0447\u0448\u0435\u0439 \u044d\u043f\u043e\u0445\u0438 \u043f\u043e \u043d\u0435\u043c\u0443 \u0432\u043e \u043c\u043d\u043e\u0433\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435\u043d. \u0422\u0435\u0441\u0442\u043e\u0432\u044b\u0439 QWK 0.7129 \u043d\u0438\u0436\u0435 \u043b\u0443\u0447\u0448\u0435\u0433\u043e \u0432\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0433\u043e 0.7555.<\/p>\n<\/li>\n<li>\n<p>\u041a\u043b\u0430\u0441\u0441\u044b DR 1 (46 \u0441\u043d\u0438\u043c\u043a\u043e\u0432) \u0438 DR 4 (20 \u0441\u043d\u0438\u043c\u043a\u043e\u0432) \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u043c\u0430\u043b\u044b, \u0438\u0445 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u043d\u0435\u0443\u0441\u0442\u043e\u0439\u0447\u0438\u0432\u044b. \u0414\u043b\u044f \u0441\u0435\u0440\u044c\u0451\u0437\u043d\u044b\u0445 \u0432\u044b\u0432\u043e\u0434\u043e\u0432 \u043d\u0443\u0436\u043d\u044b \u0431\u0443\u0442\u0441\u0442\u0440\u0435\u043f-\u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b\u044b \u043f\u043e \u0442\u0435\u0441\u0442\u0443.<\/p>\n<\/li>\n<li>\n<p>Baseline \u0441\u0440\u0430\u0432\u043d\u0438\u043c \u0441 \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0439 \u0441\u0435\u0442\u044c\u044e \u043d\u0435 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e: \u0443 \u043d\u0435\u0433\u043e \u0434\u0440\u0443\u0433\u0430\u044f \u0433\u043e\u043b\u043e\u0432\u0430 \u0438 \u043e\u0434\u0438\u043d learning rate. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432\u0435\u0441\u044c \u0440\u0430\u0437\u0440\u044b\u0432 \u043d\u0435\u043b\u044c\u0437\u044f \u0441\u043f\u0438\u0441\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b, \u0445\u043e\u0442\u044f \u043f\u0435\u0440\u0432\u044b\u0439 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442, \u0447\u0442\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u0443\u044e \u0447\u0430\u0441\u0442\u044c \u0434\u0430\u0451\u0442 \u0443\u0442\u0435\u0447\u043a\u0430.<\/p>\n<\/li>\n<li>\n<p>\u0414\u0430\u0442\u0430\u0441\u0435\u0442 \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u0439, \u043c\u0435\u0442\u043a\u0438 \u043e\u0442\u0440\u0430\u0436\u0430\u044e\u0442 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0443 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043d\u0430\u0431\u043e\u0440\u0430. \u041d\u0430 \u0434\u0440\u0443\u0433\u0438\u0435 \u043a\u0430\u043c\u0435\u0440\u044b \u0438 \u043f\u043e\u043f\u0443\u043b\u044f\u0446\u0438\u0438 \u0432\u044b\u0432\u043e\u0434\u044b \u043d\u0435 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u044f\u0442\u0441\u044f.<\/p>\n<\/li>\n<li>\n<p>\u0414\u0435\u043c\u043e-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043d\u0430 Gradio \u0432 \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435 \u0434\u043e \u0441\u0438\u0445 \u043f\u043e\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c \u0438 \u043f\u043e\u0434\u043f\u0438\u0441\u0430\u043d \u00abTest QWK = 0.8340\u00bb. \u0415\u0433\u043e \u0442\u043e\u0436\u0435 \u043d\u0443\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0435\u043b\u0430\u0442\u044c.<\/p>\n<\/li>\n<\/ul>\n<h3>\u041a\u0430\u043a \u043d\u0435 \u043f\u043e\u0432\u0442\u043e\u0440\u0438\u0442\u044c \u043c\u043e\u044e \u043e\u0448\u0438\u0431\u043a\u0443<\/h3>\n<ul>\n<li>\n<p>\u0412\u0441\u0435\u0433\u0434\u0430 \u0441\u0447\u0438\u0442\u0430\u0439\u0442\u0435 baseline \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0442\u0430\u0431\u043b\u0438\u0446\u0435. \u0415\u0441\u043b\u0438 \u043e\u043d \u043f\u043e\u0447\u0442\u0438 \u0434\u043e\u0433\u043e\u043d\u044f\u0435\u0442 \u043c\u0443\u043b\u044c\u0442\u0438\u043c\u043e\u0434\u0430\u043b\u044c\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c, \u0432\u0442\u043e\u0440\u043e\u0439 \u043f\u043e\u0442\u043e\u043a \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043e\u0442\u0432\u0435\u0442, \u0430 \u043d\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e.<\/p>\n<\/li>\n<li>\n<p>\u0427\u0438\u0442\u0430\u0439\u0442\u0435 \u043a\u043e\u0434 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432. \u0415\u0441\u043b\u0438 \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442\u0441\u044f \u043c\u0435\u0442\u043a\u0430, \u044d\u0442\u043e \u0443\u0442\u0435\u0447\u043a\u0430, \u043a\u0430\u043a \u0431\u044b \u043f\u0440\u0430\u0432\u0434\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u043e \u043d\u0438 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u0438 \u0447\u0438\u0441\u043b\u0430.<\/p>\n<\/li>\n<li>\n<p>\u041d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043e\u0431\u043d\u0443\u043b\u0435\u043d\u0438\u0435 \u0432\u0445\u043e\u0434\u0430 \u043a\u0430\u043a ablation. \u0414\u043b\u044f \u0447\u0435\u0441\u0442\u043d\u043e\u0433\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u043e\u0431\u0443\u0447\u0438\u0442\u0435 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c \u0431\u0435\u0437 \u044d\u0442\u043e\u0433\u043e \u0432\u0445\u043e\u0434\u0430.<\/p>\n<\/li>\n<li>\n<p>\u041f\u0435\u0440\u0435\u043c\u0435\u0448\u0430\u0439\u0442\u0435 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u043c\u0435\u0436\u0434\u0443 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0430\u043c\u0438 \u043d\u0430 \u0442\u0435\u0441\u0442\u0435. \u0415\u0441\u043b\u0438 \u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u043c\u0443\u043b\u044c\u0442\u0438\u043c\u043e\u0434\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438 \u0440\u0435\u0437\u043a\u043e \u043f\u0430\u0434\u0430\u0435\u0442, \u043e\u043d\u0430 \u043e\u043f\u0438\u0440\u0430\u0435\u0442\u0441\u044f \u043d\u0430 \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u043a\u0430\u043a \u043d\u0430 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0443.<\/p>\n<\/li>\n<li>\n<p>\u0421 \u043f\u043e\u0434\u043e\u0437\u0440\u0435\u043d\u0438\u0435\u043c \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u0441\u044c \u043a \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u0431\u043e\u043b\u044c\u0448\u043e\u043c\u0443 \u043f\u0440\u0438\u0440\u043e\u0441\u0442\u0443. \u0421\u043a\u0430\u0447\u043e\u043a QWK \u0441 0.45 \u0434\u043e 0.83 \u0438\u0437-\u0437\u0430 \u0447\u0435\u0442\u044b\u0440\u0451\u0445 \u0447\u0438\u0441\u0435\u043b \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u043b \u043d\u0430\u0441\u0442\u043e\u0440\u043e\u0436\u0438\u0442\u044c \u043c\u0435\u043d\u044f \u0441\u0440\u0430\u0437\u0443.<\/p>\n<\/li>\n<\/ul>\n<h3>\u0427\u0442\u043e \u0434\u0430\u043b\u044c\u0448\u0435<\/h3>\n<ul>\n<li>\n<p>\u0420\u0435\u0430\u043b\u044c\u043d\u044b\u0435 \u043f\u0430\u0440\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435, \u0433\u0434\u0435 \u0441\u043d\u0438\u043c\u043e\u043a \u0438 \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u0438 \u043e\u0442\u043d\u043e\u0441\u044f\u0442\u0441\u044f \u043a \u043e\u0434\u043d\u043e\u043c\u0443 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0443. \u0418\u0437 \u043e\u0442\u043a\u0440\u044b\u0442\u044b\u0445 \u043d\u0430\u0431\u043e\u0440\u043e\u0432 \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0442 \u0431\u0440\u0430\u0437\u0438\u043b\u044c\u0441\u043a\u0438\u0435 BRSET (16 266 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 \u043e\u0442 8 524 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u043e\u0432: \u0432\u043e\u0437\u0440\u0430\u0441\u0442, \u043f\u043e\u043b, \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430, \u043f\u0440\u0438\u0451\u043c \u0438\u043d\u0441\u0443\u043b\u0438\u043d\u0430, \u0441\u0442\u0430\u0434\u0438\u044f \u043f\u043e ICDR) \u0438 mBRSET (5 164 \u0441\u043d\u0438\u043c\u043a\u0430 \u0441 \u043f\u043e\u0440\u0442\u0430\u0442\u0438\u0432\u043d\u044b\u0445 \u043a\u0430\u043c\u0435\u0440 \u043e\u0442 1 291 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0430 \u0441 \u0434\u0438\u0430\u0431\u0435\u0442\u043e\u043c: \u0432\u043e\u0437\u0440\u0430\u0441\u0442, \u043f\u043e\u043b, \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430, \u0438\u043d\u0441\u0443\u043b\u0438\u043d, \u0433\u0438\u043f\u0435\u0440\u0442\u0435\u043d\u0437\u0438\u044f). HbA1c \u0432 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0438 \u0438\u0445 \u043f\u043e\u043b\u0435\u0439 \u044f \u043d\u0435 \u043d\u0430\u0448\u0451\u043b, \u0430 \u0432 BRSET \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430 \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u043e\u0432 \u0441 \u0434\u0438\u0430\u0431\u0435\u0442\u043e\u043c.<\/p>\n<\/li>\n<li>\n<p>\u0420\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 512\u00d7512, \u0447\u0442\u043e\u0431\u044b \u043c\u0438\u043a\u0440\u043e\u0430\u043d\u0435\u0432\u0440\u0438\u0437\u043c\u044b \u043d\u0430 \u0433\u0440\u0430\u043d\u0438\u0446\u0435 DR 1 \u0438 DR 2 \u0437\u0430\u043d\u0438\u043c\u0430\u043b\u0438 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439.<\/p>\n<\/li>\n<li>\n<p>\u041f\u043e\u0440\u044f\u0434\u043a\u043e\u0432\u044b\u0439 \u043b\u043e\u0441\u0441 (CORAL \u0438\u043b\u0438 \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f \u0441 \u043f\u043e\u0440\u043e\u0433\u0430\u043c\u0438): \u0441\u0442\u0430\u0434\u0438\u0438 \u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0435\u043d\u044b, \u0438 \u043e\u0431\u044b\u0447\u043d\u0430\u044f \u043a\u0440\u043e\u0441\u0441-\u044d\u043d\u0442\u0440\u043e\u043f\u0438\u044f \u044d\u0442\u043e \u043d\u0435 \u0443\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442.<\/p>\n<\/li>\n<li>\n<p>\u0411\u0443\u0442\u0441\u0442\u0440\u0435\u043f-\u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b\u044b \u0438 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u0438\u0434\u043e\u0432.<\/p>\n<\/li>\n<li>\n<p>Grad-CAM \u0434\u043b\u044f \u043c\u043e\u0434\u0435\u043b\u0438 \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c: \u0445\u0443\u043a\u0438 \u043d\u0430 <code>conv_head<\/code> \u0443\u0436\u0435 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u044b \u0434\u043b\u044f \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0439 \u0441\u0435\u0442\u0438, \u0438\u0445 \u043d\u0443\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u0432 <code>HonestVisionOnlyNet<\/code>.<\/p>\n<\/li>\n<\/ul>\n<p>\u041f\u0440\u043e\u0442\u043e\u0442\u0438\u043f \u043d\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043c\u0435\u0434\u0438\u0446\u0438\u043d\u0441\u043a\u0438\u043c \u0438\u0437\u0434\u0435\u043b\u0438\u0435\u043c \u0438 \u043d\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u0434\u0438\u0430\u0433\u043d\u043e\u0441\u0442\u0438\u043a\u0438.<\/p>\n<h3>\u0412\u044b\u0432\u043e\u0434<\/h3>\n<p>\u041a\u0440\u0430\u0441\u0438\u0432\u0430\u044f \u043c\u0435\u0442\u0440\u0438\u043a\u0430 \u043c\u0443\u043b\u044c\u0442\u0438\u043c\u043e\u0434\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u043e\u0434\u0435\u043b\u0438 \u043e\u043a\u0430\u0437\u0430\u043b\u0430\u0441\u044c \u0430\u0440\u0442\u0435\u0444\u0430\u043a\u0442\u043e\u043c \u0434\u0430\u043d\u043d\u044b\u0445. \u041c\u043e\u0434\u0435\u043b\u044c \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c \u0434\u0430\u0451\u0442 QWK 0.71 \u0438 \u0441\u043b\u0430\u0431\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430 \u043f\u043e\u0433\u0440\u0430\u043d\u0438\u0447\u043d\u044b\u0445 \u0441\u0442\u0430\u0434\u0438\u044f\u0445. \u0421 \u044d\u0442\u043e\u0439 \u0446\u0438\u0444\u0440\u044b \u0438 \u0441\u0442\u043e\u0438\u0442 \u043d\u0430\u0447\u0438\u043d\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u044b, \u0430 \u043d\u0435 \u0441 0.83. \u0415\u0441\u043b\u0438 \u043a\u043e\u043c\u0443-\u0442\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e \u043f\u043e\u0434\u0435\u043b\u044e\u0441\u044c \u0431\u043b\u043e\u043a\u043d\u043e\u0442\u043e\u043d<\/p>\n<\/div>\n<p>\u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/1095572\/\">https:\/\/habr.com\/ru\/articles\/1095572\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u041f\u0440\u0435\u0434\u044b\u0441\u0442\u043e\u0440\u0438\u044f\u042f \u0441\u043e\u0431\u0440\u0430\u043b \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c: \u043e\u043d\u0430 \u0441\u043c\u043e\u0442\u0440\u0438\u0442 \u043d\u0430 \u0441\u043d\u0438\u043c\u043e\u043a \u0433\u043b\u0430\u0437\u043d\u043e\u0433\u043e \u0434\u043d\u0430 \u0438 \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u0438 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0430. \u041d\u0430 \u043e\u0442\u043b\u043e\u0436\u0435\u043d\u043d\u043e\u043c \u0442\u0435\u0441\u0442\u0435 \u043f\u0435\u0440\u0432\u044b\u0439 \u0437\u0430\u043f\u0443\u0441\u043a \u0434\u0430\u043b QWK 0.834. \u041f\u043e\u0442\u043e\u043c \u044f \u0441\u0442\u0430\u043b \u0440\u0430\u0437\u0431\u0438\u0440\u0430\u0442\u044c\u0441\u044f, \u0437\u0430 \u0441\u0447\u0451\u0442 \u0447\u0435\u0433\u043e, \u0438 \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0432 \u043c\u043e\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u043e\u0442\u0432\u0435\u0442. \u042f \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0442\u0440\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c\u043d\u044b\u0445 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u043e\u0431\u0443\u0447\u0438\u043b \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e \u043c\u043e\u0434\u0435\u043b\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c. \u0423 \u043d\u0435\u0451 QWK 0.713. \u041d\u0438\u0436\u0435 \u0432\u0435\u0441\u044c \u043f\u0430\u0439\u043f\u043b\u0430\u0439\u043d \u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u0442\u0430\u043a\u0430\u044f \u0443\u0442\u0435\u0447\u043a\u0430 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f.\u0410\u043d\u0430\u043b\u0438\u0437\u0412 RetinaMNIST \u0435\u0441\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u043d\u0438\u043c\u043a\u0438, \u0430\u043d\u0430\u043b\u0438\u0437\u043e\u0432 \u0442\u0430\u043c \u043d\u0435\u0442. \u042f \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0438\u0445 \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435, \u0432 \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0432\u0445\u043e\u0434\u0438\u043b\u0430 \u0438\u0441\u0442\u0438\u043d\u043d\u0430\u044f \u0441\u0442\u0430\u0434\u0438\u044f \u0431\u043e\u043b\u0435\u0437\u043d\u0438, \u0438 \u0441\u0435\u0442\u044c \u043d\u0430\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0447\u0438\u0442\u0430\u0442\u044c \u044d\u0442\u0443 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0443. \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u043d\u0430 \u0442\u0435\u0441\u0442\u0435 \u0438\u0437 400 \u0441\u043d\u0438\u043c\u043a\u043e\u0432:\u041c\u043e\u0434\u0435\u043b\u044cQWKMacro AUC\u041b\u043e\u0433\u0438\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u0438\u043d\u0442\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c, \u0431\u0435\u0437 \u0441\u043d\u0438\u043c\u043a\u04300.81630.8823\u0414\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c, \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0441 \u0443\u0442\u0435\u0447\u043a\u043e\u04390.83400.8588\u0414\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c \u0441 \u043e\u0431\u043d\u0443\u043b\u0451\u043d\u043d\u044b\u043c \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u043c \u0432\u0445\u043e\u0434\u043e\u043c (\u043d\u0435\u0432\u0435\u0440\u043d\u044b\u0439 baseline)0.45020.7774EfficientNet-B2, \u043e\u0431\u0443\u0447\u0435\u043d\u043d\u044b\u0439 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 \u0441\u043d\u0438\u043c\u043a\u0430\u04450.71290.8070\u0420\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f, \u043d\u0435 \u0432\u0438\u0434\u0435\u0432\u0448\u0430\u044f \u043d\u0438 \u043e\u0434\u043d\u043e\u0433\u043e \u043f\u0438\u043a\u0441\u0435\u043b\u044f, \u043f\u043e\u0447\u0442\u0438 \u0434\u043e\u0433\u043e\u043d\u044f\u0435\u0442 \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0443\u044e \u0441\u0435\u0442\u044c \u043f\u043e QWK \u0438 \u043e\u0431\u0433\u043e\u043d\u044f\u0435\u0442 \u0435\u0451 \u043f\u043e AUC. \u041f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c \u043c\u043e\u0434\u0435\u043b\u044c \u043d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u0434\u0430\u0451\u0442 QWK \u043e\u043a\u043e\u043b\u043e 0.71.\u0417\u0430\u0447\u0435\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u043f\u043e\u0442\u043e\u043a\u0412\u0440\u0430\u0447 \u043d\u0435 \u043e\u0446\u0435\u043d\u0438\u0432\u0430\u0435\u0442 \u0441\u043d\u0438\u043c\u043e\u043a \u0432 \u043e\u0442\u0440\u044b\u0432\u0435 \u043e\u0442 \u043f\u0430\u0446\u0438\u0435\u043d\u0442\u0430: \u043e\u043d \u0441\u043c\u043e\u0442\u0440\u0438\u0442 \u043d\u0430 \u0433\u043b\u0438\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0433\u0435\u043c\u043e\u0433\u043b\u043e\u0431\u0438\u043d (HbA1c), \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430, \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u0435. \u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0444\u0443\u043d\u0434\u0443\u0441-\u043a\u0430\u043c\u0435\u0440\u044b \u0434\u0430\u044e\u0442 \u043d\u0435\u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u0443\u044e \u0437\u0430\u0441\u0432\u0435\u0442\u043a\u0443, \u0430 \u0431\u0435\u0437 \u043a\u0430\u0440\u0442\u044b \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u043d\u0435\u043f\u043e\u043d\u044f\u0442\u043d\u043e, \u043d\u0430 \u0447\u0442\u043e \u043e\u0442\u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043b\u0430 \u0441\u0435\u0442\u044c: \u043d\u0430 \u044d\u043a\u0441\u0441\u0443\u0434\u0430\u0442 \u0438\u043b\u0438 \u043d\u0430 \u043f\u044b\u043b\u0438\u043d\u043a\u0443 \u043d\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0438\u0432\u0435. \u041e\u0442\u0441\u044e\u0434\u0430 \u043f\u043b\u0430\u043d: \u043f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0434\u0447\u0451\u0440\u043a\u0438\u0432\u0430\u0435\u0442 \u0441\u043e\u0441\u0443\u0434\u044b \u0438 \u043e\u0447\u0430\u0433\u0438, \u0432\u0442\u043e\u0440\u043e\u0439 \u0432\u0445\u043e\u0434 \u0434\u043b\u044f \u043a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0438 Grad-CAM \u0434\u043b\u044f \u043e\u0431\u044a\u044f\u0441\u043d\u0435\u043d\u0438\u044f.\u0421\u0430\u043c \u043f\u043b\u0430\u043d \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439. \u041f\u043e\u0434\u0432\u0435\u043b\u0438 \u0434\u0430\u043d\u043d\u044b\u0435, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u044f \u0435\u0433\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u043b.\u0414\u0430\u043d\u043d\u044b\u0435\u042f \u0432\u0437\u044f\u043b RetinaMNIST \u0438\u0437 MedMNIST: 1600 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 \u0433\u043b\u0430\u0437\u043d\u043e\u0433\u043e \u0434\u043d\u0430 \u0438\u0437 \u0441\u043e\u0440\u0435\u0432\u043d\u043e\u0432\u0430\u043d\u0438\u044f DeepDRiD, \u043f\u044f\u0442\u044c \u0441\u0442\u0430\u0434\u0438\u0439 \u043f\u043e \u0448\u043a\u0430\u043b\u0435 ICDR, \u0432\u0435\u0440\u0441\u0438\u044f 224\u00d7224 \u0441 \u0433\u043e\u0442\u043e\u0432\u044b\u043c\u0438 \u0441\u043f\u043b\u0438\u0442\u0430\u043c\u0438.DR 0: \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432 \u0440\u0435\u0442\u0438\u043d\u043e\u043f\u0430\u0442\u0438\u0438 \u043d\u0435\u0442DR 1: \u043b\u0451\u0433\u043a\u0430\u044f \u043d\u0435\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044fDR 2: \u0443\u043c\u0435\u0440\u0435\u043d\u043d\u0430\u044f \u043d\u0435\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044fDR 3: \u0442\u044f\u0436\u0451\u043b\u0430\u044f \u043d\u0435\u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044fDR 4: \u043f\u0440\u043e\u043b\u0438\u0444\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f\u0421\u043f\u043b\u0438\u0442\u044b: train 1080, validation 120, test 400. \u041a\u043b\u0430\u0441\u0441\u044b \u043d\u0435\u0441\u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u044b: \u0432 \u0442\u0435\u0441\u0442\u0435 174 \u0441\u043d\u0438\u043c\u043a\u0430 DR 0 \u0438 \u0432\u0441\u0435\u0433\u043e 20 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 DR 4.pythonfrom medmnist import RetinaMNISTtrain_data = RetinaMNIST(split=&#187;train&#187;, download=True, size=224)val_data   = RetinaMNIST(split=&#187;val&#187;,   download=True, size=224)test_data  = RetinaMNIST(split=&#187;test&#187;,  download=True, size=224)from medmnist import RetinaMNIST  train_data = RetinaMNIST(split=&#187;train&#187;, download=True, size=224) val_data   = RetinaMNIST(split=&#187;val&#187;,   download=True, size=224) test_data  = RetinaMNIST(split=&#187;test&#187;,  download=True, size=224)\u0412 \u043d\u043e\u0443\u0442\u0431\u0443\u043a\u0435 \u043f\u0435\u0440\u0435\u0434 \u044d\u0442\u0438\u043c \u0441\u0442\u043e\u0438\u0442 \u043f\u043e\u043f\u044b\u0442\u043a\u0430 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c APTOS 2019 \u0447\u0435\u0440\u0435\u0437 kagglehub. \u0412 \u043c\u043e\u0451\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u043e\u043d\u0430 \u043d\u0435 \u0441\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u0430, \u043a\u043e\u0434 \u043f\u0435\u0440\u0435\u0448\u0451\u043b \u043d\u0430 RetinaMNIST, \u0438 \u0432\u0441\u0435 \u0446\u0438\u0444\u0440\u044b \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u044b \u043d\u0430 \u043d\u0451\u043c.\u041f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433: \u0411\u0435\u043d \u0413\u0440\u044d\u043c \u0438 CLAHE\u0427\u0442\u043e\u0431\u044b \u0443\u0431\u0440\u0430\u0442\u044c \u043d\u0435\u0440\u0430\u0432\u043d\u043e\u043c\u0435\u0440\u043d\u0443\u044e \u0437\u0430\u0441\u0432\u0435\u0442\u043a\u0443, \u0438\u0437 \u0441\u043d\u0438\u043c\u043a\u0430 \u0432\u044b\u0447\u0438\u0442\u0430\u0435\u0442\u0441\u044f \u0435\u0433\u043e \u0436\u0435 \u043a\u043e\u043f\u0438\u044f, \u0440\u0430\u0437\u043c\u044b\u0442\u0430\u044f \u0433\u0430\u0443\u0441\u0441\u043e\u0432\u044b\u043c \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u043c. \u042d\u0442\u043e\u0442 \u043f\u0440\u0438\u0451\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u043f\u043e\u0431\u0435\u0434\u0438\u0442\u0435\u043b\u044c \u0441\u043e\u0440\u0435\u0432\u043d\u043e\u0432\u0430\u043d\u0438\u044f Kaggle Diabetic Retinopathy Detection:textI_enh = 4 * I &#8212; 4 * G_sigma(I) + 128I_enh = 4  I &#8212; 4  G_sigma(I) + 128\u041f\u043b\u0430\u0432\u043d\u044b\u0439 \u0433\u0440\u0430\u0434\u0438\u0435\u043d\u0442 \u044f\u0440\u043a\u043e\u0441\u0442\u0438 \u0443\u0445\u043e\u0434\u0438\u0442, \u0430 \u0441\u043e\u0441\u0443\u0434\u044b, \u0433\u0435\u043c\u043e\u0440\u0440\u0430\u0433\u0438\u0438 \u0438 \u044d\u043a\u0441\u0441\u0443\u0434\u0430\u0442\u044b \u043e\u0441\u0442\u0430\u044e\u0442\u0441\u044f. \u041f\u043e\u0442\u043e\u043c CLAHE \u043f\u043e \u043a\u0430\u043d\u0430\u043b\u0443 \u044f\u0440\u043a\u043e\u0441\u0442\u0438 \u0432 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 LAB:pythondef apply_ben_graham_preprocessing(image_np, size=224, sigmaX=10):    img = cv2.resize(image_np, (size, size))    mask = np.zeros((size, size), dtype=np.uint8)    cv2.circle(mask, (size \/\/ 2, size \/\/ 2), int(size * 0.46), 255, -1)    blurred = cv2.GaussianBlur(img, (0, 0), sigmaX)    enhanced = cv2.addWeighted(img, 4, blurred, -4, 128)    lab = cv2.cvtColor(enhanced, cv2.COLOR_RGB2LAB)    l, a, b = cv2.split(lab)    clahe = cv2.createCLAHE(clipLimit=2.0, tileGridSize=(8, 8))    l = clahe.apply(l)    enhanced = cv2.cvtColor(cv2.merge((l, a, b)), cv2.COLOR_LAB2RGB)    return cv2.bitwise_and(enhanced, enhanced, mask=mask)\u0420\u0438\u0441\u0443\u043d\u043e\u043a 1 &#8212; \u041d\u0430\u0433\u043b\u044f\u0434\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440\u041d\u0430 \u0441\u0442\u0430\u0434\u0438\u044f\u0445 DR 2\u20134 \u043f\u043e\u0441\u043b\u0435 \u0444\u0438\u043b\u044c\u0442\u0440\u0430 \u043d\u0430 \u0441\u0435\u0440\u043e\u043c \u0444\u043e\u043d\u0435 \u0432\u0438\u0434\u043d\u044b \u0442\u0451\u043c\u043d\u044b\u0435 \u043a\u0440\u043e\u0432\u043e\u0438\u0437\u043b\u0438\u044f\u043d\u0438\u044f \u0438 \u0441\u0432\u0435\u0442\u043b\u044b\u0435 \u043e\u0447\u0430\u0433\u0438 \u044d\u043a\u0441\u0441\u0443\u0434\u0430\u0446\u0438\u0438.\u041f\u0435\u0440\u0432\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f: \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u0430\u044f \u0441\u0435\u0442\u044c\u0412\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u044b\u0439 \u044d\u043d\u043a\u043e\u0434\u0435\u0440 \u2014 efficientnet_b2 \u0438\u0437 timm. \u0422\u0430\u0431\u043b\u0438\u0447\u043d\u0430\u044f \u0432\u0435\u0442\u043a\u0430 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0438\u0442 \u0447\u0435\u0442\u044b\u0440\u0435 \u043d\u043e\u0440\u043c\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044f (HbA1c, \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430, \u0441\u0438\u0441\u0442\u043e\u043b\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0434\u0430\u0432\u043b\u0435\u043d\u0438\u0435, \u0432\u043e\u0437\u0440\u0430\u0441\u0442) \u0432 32-\u043c\u0435\u0440\u043d\u044b\u0439 \u0432\u0435\u043a\u0442\u043e\u0440. \u041f\u0435\u0440\u0435\u0434 \u043a\u043b\u0430\u0441\u0441\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u043e\u043c \u0432\u0435\u043a\u0442\u043e\u0440 \u0441\u043d\u0438\u043c\u043a\u0430 (1408 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432) \u0441\u043a\u043b\u0435\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u043c, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f 1440. \u041d\u0430 conv_head \u043f\u043e\u0432\u0435\u0448\u0435\u043d\u044b \u0445\u0443\u043a\u0438 \u0434\u043b\u044f Grad-CAM, \u0432 \u043b\u0438\u0441\u0442\u0438\u043d\u0433\u0435 \u043d\u0438\u0436\u0435 \u044f \u0438\u0445 \u043e\u043f\u0443\u0441\u0442\u0438\u043b.pythonclass RetinaTwoStreamNet(nn.Module):    def __init__(self, backbone_name=&#187;efficientnet_b2&#8243;, num_classes=5, tabular_dim=4):        super().__init__()        self.backbone = timm.create_model(backbone_name, pretrained=True,                                          num_classes=0, global_pool=&#187;&#187;)        vision_dim = self.backbone.num_features  # 1408        self.pool = nn.AdaptiveAvgPool2d(1)        self.tabular_net = nn.Sequential(            nn.Linear(tabular_dim, 32), nn.BatchNorm1d(32), nn.SiLU(),            nn.Dropout(0.2), nn.Linear(32, 32), nn.SiLU()        )        self.classifier = nn.Sequential(            nn.Linear(vision_dim + 32, 256), nn.BatchNorm1d(256), nn.SiLU(),            nn.Dropout(0.35), nn.Linear(256, num_classes)        )    def forward(self, img_tensor, tab_tensor):        v_emb = self.pool(self.backbone(img_tensor)).flatten(1)        t_emb = self.tabular_net(tab_tensor)        return self.classifier(torch.cat([v_emb, t_emb], dim=1))\u041e\u0431\u0443\u0447\u0435\u043d\u0438\u0435: \u0432\u0435\u0441\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u043e\u0431\u0440\u0430\u0442\u043d\u043e \u043f\u0440\u043e\u043f\u043e\u0440\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b \u0438\u0445 \u0447\u0430\u0441\u0442\u043e\u0442\u0435 \u0432 train, label_smoothing=0.05, AdamW \u0441 \u0440\u0430\u0437\u0434\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0448\u0430\u0433\u0430\u043c\u0438 (\u0431\u044d\u043a\u0431\u043e\u043d 3e-4, \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u0430\u044f \u0432\u0435\u0442\u043a\u0430 \u0438 \u0433\u043e\u043b\u043e\u0432\u0430 1.2e-3), \u043a\u043e\u0441\u0438\u043d\u0443\u0441\u043d\u043e\u0435 \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435, AMP FP16, \u0430\u0443\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Albumentations (\u043f\u043e\u0432\u043e\u0440\u043e\u0442\u044b \u0434\u043e 180\u00b0, \u0444\u043b\u0438\u043f\u044b, \u044f\u0440\u043a\u043e\u0441\u0442\u044c \u0438 \u043a\u043e\u043d\u0442\u0440\u0430\u0441\u0442). 12 \u044d\u043f\u043e\u0445 \u043d\u0430 Tesla T4 \u0437\u0430\u043d\u044f\u043b\u0438 184.9 \u0441\u0435\u043a\u0443\u043d\u0434\u044b. \u041b\u0443\u0447\u0448\u0438\u0439 \u0447\u0435\u043a\u043f\u043e\u0438\u043d\u0442 \u0432\u044b\u0431\u0440\u0430\u043d \u043f\u043e \u0432\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u043c\u0443 QWK: 0.8844 \u043d\u0430 10-\u0439 \u044d\u043f\u043e\u0445\u0435.\u041d\u0430 \u0442\u0435\u0441\u0442\u0435: QWK 0.8340, Macro AUC 0.8588, accuracy 0.6325.\u0420\u0438\u0441\u0443\u043d\u043e\u043a 2 &#8212; \u041c\u0435\u0442\u0440\u0438\u043a\u0438.\u0427\u0442\u043e \u043d\u0435 \u0441\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c\u0427\u0435\u0442\u044b\u0440\u0435 \u0447\u0438\u0441\u043b\u0430 \u043d\u0430 \u0432\u0445\u043e\u0434\u0435 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0438 \u0434\u0430\u0432\u0430\u043b\u0438 \u0441\u0435\u0442\u0438 \u0431\u043e\u043b\u044c\u0448\u0435, \u0447\u0435\u043c 1408 \u0432\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432. \u041a\u043e\u0433\u0434\u0430 \u044f \u043e\u0431\u043d\u0443\u043b\u044f\u043b \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u0439 \u0432\u0445\u043e\u0434, QWK \u043f\u0430\u0434\u0430\u043b \u0441 0.83 \u0434\u043e 0.45. \u0412 \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u0439 \u043a\u043b\u0438\u043d\u0438\u043a\u0435 HbA1c \u0438 \u0441\u0442\u0430\u0436 \u0434\u0438\u0430\u0431\u0435\u0442\u0430 \u0441\u0432\u044f\u0437\u0430\u043d\u044b \u0441 \u0440\u0438\u0441\u043a\u043e\u043c \u0440\u0435\u0442\u0438\u043d\u043e\u043f\u0430\u0442\u0438\u0438, \u043d\u043e \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0441\u0442\u0430\u0434\u0438\u044e \u043f\u043e \u043d\u0438\u043c \u043d\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c: \u043e\u043d\u0430 \u0432\u0438\u0434\u043d\u0430 \u043d\u0430 \u0441\u043d\u0438\u043c\u043a\u0435. \u0421\u0442\u043e\u043b\u044c \u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0432\u043a\u043b\u0430\u0434 \u0447\u0435\u0442\u044b\u0440\u0451\u0445 \u0447\u0438\u0441\u0435\u043b \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b \u0441\u0442\u0440\u0430\u043d\u043d\u043e, \u0438 \u044f \u0432\u0435\u0440\u043d\u0443\u043b\u0441\u044f \u043a \u0442\u043e\u043c\u0443, \u043a\u0430\u043a \u044d\u0442\u0438 \u0447\u0438\u0441\u043b\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u044b.\u041e\u0442\u043a\u0443\u0434\u0430 \u0432\u0437\u044f\u043b\u0438\u0441\u044c \u00ab\u0430\u043d\u0430\u043b\u0438\u0437\u044b\u00bb\u041a\u043b\u0438\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 RetinaMNIST \u043d\u0435\u0442, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0430\u0442\u0430\u0441\u0435\u0442 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0438\u0445 \u0441\u0430\u043c:pythondef _sample_clinical_ehr(self, stage, idx):    rng = np.random if self.is_train else np.random.RandomState(idx + 5000)    hba1c    = np.clip(5.9 + stage * 0.85 + rng.normal(0, 1.15), 4.5, 14.5)    duration = np.clip(2.5 + stage * 3.1  + rng.normal(0, 3.8),  0.0, 35.0)    sys_bp   = np.clip(122 + stage * 6.5  + rng.normal(0, 12.0), 90.0, 200.0)    age      = np.clip(46 + stage * 3.5   + rng.normal(0, 9.5),  20.0, 88.0)    return torch.tensor([(hba1c &#8212; 6.0) \/ 5.0, duration \/ 20.0,                         (sys_bp &#8212; 120.0) \/ 40.0, (age &#8212; 50.0) \/ 25.0])\u041d\u0430 \u0432\u0445\u043e\u0434 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043f\u043e\u0434\u0430\u0451\u0442\u0441\u044f stage, \u0442\u043e \u0435\u0441\u0442\u044c \u0438\u0441\u0442\u0438\u043d\u043d\u0430\u044f \u043c\u0435\u0442\u043a\u0430, \u0430 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u044e\u0442\u0441\u044f \u0438\u0437 \u043d\u0435\u0451 \u043b\u0438\u043d\u0435\u0439\u043d\u043e \u0441 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u0433\u0430\u0443\u0441\u0441\u043e\u0432\u0430 \u0448\u0443\u043c\u0430. \u042f \u0445\u043e\u0442\u0435\u043b \u00ab\u0440\u0435\u0430\u043b\u0438\u0441\u0442\u0438\u0447\u043d\u0443\u044e \u043a\u043e\u0440\u0440\u0435\u043b\u044f\u0446\u0438\u044e \u0441\u043e \u0441\u0442\u0430\u0434\u0438\u0435\u0439\u00bb, \u0430 \u043f\u043e\u043b\u0443\u0447\u0438\u043b \u0443\u0442\u0435\u0447\u043a\u0443 \u043c\u0435\u0442\u043a\u0438. \u041f\u0440\u0438\u0447\u0451\u043c \u043d\u0430 \u0442\u0435\u0441\u0442\u0435 \u0442\u043e\u0436\u0435: \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0441\u0442\u0440\u043e\u044f\u0442\u0441\u044f \u043f\u043e \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u043c \u043c\u0435\u0442\u043a\u0430\u043c. \u0421\u0435\u0442\u0438 \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0443\u0447\u0438\u0442\u044c\u0441\u044f \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0443, \u0435\u0439 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0447\u0435\u0442\u044b\u0440\u0435 \u0447\u0438\u0441\u043b\u0430.\u041d\u0430 train \u0448\u0443\u043c \u043a \u0442\u043e\u043c\u0443 \u0436\u0435 \u043f\u0435\u0440\u0435\u0441\u044d\u043c\u043f\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u043a\u0430\u0436\u0434\u043e\u043c \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u0438 \u043a \u043f\u0440\u0438\u043c\u0435\u0440\u0443, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0442\u0430\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 np.random. \u041f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f \u0430\u0443\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u0445 \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u043e\u0432, \u0438 \u0441\u0435\u0442\u044c \u0443\u0447\u0438\u0442\u0441\u044f \u0432\u044b\u0442\u0430\u0441\u043a\u0438\u0432\u0430\u0442\u044c \u0441\u0442\u0430\u0434\u0438\u044e \u0438\u0437 \u043b\u044e\u0431\u043e\u0439 \u0437\u0430\u0448\u0443\u043c\u043b\u0451\u043d\u043d\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0438.\u0422\u0440\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044c\u043d\u044b\u0445 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u04301. \u041b\u043e\u0433\u0438\u0441\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u0438\u043d\u0442\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u043c \u043f\u0440\u0438\u0437\u043d\u0430\u043a\u0430\u043c\u0415\u0441\u043b\u0438 \u0441\u043d\u0438\u043c\u043e\u043a \u043d\u0435 \u043d\u0443\u0436\u0435\u043d, \u043c\u043e\u0434\u0435\u043b\u044c \u0431\u0435\u0437 \u0441\u043d\u0438\u043c\u043a\u0430 \u0434\u043e\u043b\u0436\u043d\u0430 \u0434\u0430\u0442\u044c \u0441\u043e\u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043c\u044b\u0439 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442. \u041f\u0440\u0438\u0437\u043d\u0430\u043a\u0438 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u043f\u043e \u0442\u0435\u043c \u0436\u0435 \u0444\u043e\u0440\u043c\u0443\u043b\u0430\u043c, \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u0441 \u0442\u0435\u043c\u0438 \u0436\u0435 \u0441\u0438\u0434\u0430\u043c\u0438 idx + 5000:pythonclf_leak = LogisticRegression(max_iter=500)clf_leak.fit(X_tab_train, y_train)leak_preds = clf_leak.predict(X_tab_test)leak_probs = clf_leak.predict_proba(X_tab_test)leak_qwk = cohen_kappa_score(y_test, leak_preds, weights=&#187;quadratic&#187;)leak_auc = roc_auc_score(y_test, leak_probs, multi_class=&#187;ovr&#187;, average=&#187;macro&#187;)clf_leak = LogisticRegression(max_iter=500) clf_leak.fit(X_tab_train, y_train) leak_preds = clf_leak.predict(X_tab_test) leak_probs = clf_leak.predict_proba(X_tab_test)  leak_qwk = cohen_kappa_score(y_test, leak_preds, weights=&#187;quadratic&#187;) leak_auc = roc_auc_score(y_test, leak_probs, multi_class=&#187;ovr&#187;, average=&#187;macro&#187;)QWK 0.8163, Macro AUC 0.8823. \u041b\u0438\u043d\u0435\u0439\u043d\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u043f\u043e \u0447\u0435\u0442\u044b\u0440\u0451\u043c \u0447\u0438\u0441\u043b\u0430\u043c \u043f\u043e\u0447\u0442\u0438 \u0440\u0430\u0432\u043d\u0430 \u0434\u0432\u0443\u0445\u043f\u043e\u0442\u043e\u0447\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u043f\u043e QWK \u0438 \u0432\u044b\u0448\u0435 \u043d\u0435\u0451 \u043f\u043e AUC. \u0414\u0440\u0443\u0433\u0438\u0445 \u0434\u043e\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c\u0441\u0442\u0432 \u0443\u0442\u0435\u0447\u043a\u0438 \u0443\u0436\u0435 \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f.2. \u041e\u0431\u043d\u0443\u043b\u0435\u043d\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u043e\u0433\u043e \u0432\u0445\u043e\u0434\u0430QWK 0.4502, AUC 0.7774. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u044f \u0441\u0447\u0438\u0442\u0430\u043b \u044d\u0442\u043e \u00ab\u043a\u0430\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0431\u0435\u0437 \u0430\u043d\u0430\u043b\u0438\u0437\u043e\u0432\u00bb, \u0438 \u044d\u0442\u043e \u0431\u044b\u043b\u0430 \u043e\u0448\u0438\u0431\u043a\u0430. \u041c\u043e\u0434\u0435\u043b\u044c \u043e\u0431\u0443\u0447\u0430\u043b\u0430\u0441\u044c \u0441 \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u043c \u0432\u0445\u043e\u0434\u043e\u043c, \u0438 \u043d\u0443\u043b\u0435\u0432\u043e\u0439 \u0432\u0435\u043a\u0442\u043e\u0440 \u0434\u043b\u044f \u043d\u0435\u0451 \u2014 \u0432\u0445\u043e\u0434 \u0438\u0437 \u0434\u0440\u0443\u0433\u043e\u0433\u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f. \u0422\u0430\u043a \u0438\u0437\u043c\u0435\u0440\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u043e\u043c\u0430\u043d\u043d\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c, \u0430 \u043d\u0435 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u043e \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c.3. \u041e\u0442\u0434\u0435\u043b\u044c\u043d\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0441\u043d\u0438\u043c\u043a\u0430\u043c\u041f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u0439 baseline: \u0442\u043e\u0442 \u0436\u0435 efficientnet_b2 \u0441 \u0432\u0435\u0441\u0430\u043c\u0438 ImageNet, \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u0430\u044f \u0433\u043e\u043b\u043e\u0432\u0430 timm (\u043f\u0443\u043b\u0438\u043d\u0433 \u0438 \u043b\u0438\u043d\u0435\u0439\u043d\u044b\u0439 \u0441\u043b\u043e\u0439), \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0438 \u043d\u0435\u0442. \u041f\u0440\u0435\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0438\u043d\u0433, \u0430\u0443\u0433\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438, \u0432\u0435\u0441\u0430 \u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0438 label_smoothing \u0442\u0435 \u0436\u0435, \u043d\u043e learning rate \u043e\u0434\u0438\u043d, 3e-4, \u0441 \u043a\u043e\u0441\u0438\u043d\u0443\u0441\u043d\u044b\u043c \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435\u043c \u043d\u0430 12 \u044d\u043f\u043e\u0445.pythonclass HonestVisionOnlyNet(nn.Module):    def __init__(self, backbone_name=&#187;efficientnet_b2&#8243;, num_classes=5):        super().__init__()        self.backbone = timm.create_model(backbone_name, pretrained=True,                                          num_classes=num_classes)    def forward(self, img_tensor):        return self.backbone(img_tensor)optimizer = torch.optim.AdamW(honest_model.parameters(), lr=3e-4, weight_decay=1e-2)scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, T_max=12)criterion = nn.CrossEntropyLoss(weight=class_weights, label_smoothing=0.05)class HonestVisionOnlyNet(nn.Module):     def init(self, backbone_name=&#187;efficientnet_b2&#8243;, num_classes=5):         super().__init__()         self.backbone = timm.create_model(backbone_name, pretrained=True,                                           num_classes=num_classes)      def forward(self, img_tensor):         return self.backbone(img_tensor)  optimizer = torch.optim.AdamW(honest_model.parameters(), lr=3e-4, weight_decay=1e-2) scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, T_max=12) criterion =&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-499042","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/499042","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=499042"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/499042\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=499042"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=499042"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=499042"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}