Сопоставление признаков: Зиновьев Тимофей#5
Open
Zetix3 wants to merge 3 commits into
Open
Conversation
ismukhin
reviewed
Nov 19, 2025
There was a problem hiding this comment.
Ячейка 2:
- Размер пачки желательно должен быть кратным степени двойки из соображений, связанных с производительностью (например, на ядрах cuda лучшая производительность достигается при размерах пачки, кратных степени двойки)
for i, ax in enumerate(axes.flat):
img = images[i][0].numpy().transpose(1, 2, 0)
img = img * [0.247, 0.243, 0.261] + [0.491, 0.482, 0.446]
img = np.clip(img, 0, 1)
ax.imshow(img)
label = images[i][1]
class_name = class_names[label]
ax.set_xlabel(f'{class_name}', fontsize=8, labelpad=2)Очень странная строчка img = img * [0.247, 0.243, 0.261] + [0.491, 0.482, 0.446], что это?
- Впервые вижу такие значения средних и стандартных отклонений
torchvision.transforms.Normalize((0.491, 0.482, 0.446), (0.247, 0.243, 0.261)), откуда они?
There was a problem hiding this comment.
Ощущение, что вы переобучили модель примерно после 15 эпохи, итоговые значения точности по тестовой и тренировочной выборок отличаются на 10%.
There was a problem hiding this comment.
Еще по поводу mean и std: они у вас в диапазоне от 0 до 1, при этом вы не делаете нормировку изображения, соответственно, это получается не совсем корректно. Либо умножаете значения mean и std на 255, либо нормируете всё изображение, после чего применяете необходимые трансформации
Author
|
@ismukhin Сделал 3-ю лабу |
Author
|
@ismukhin поправил 2-ю лабу (CNN) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.