💡 [REQUEST] - Neural Style Transfer: use AvgPool2d
Maintainer thường phản hồi trong vòng 2 ngày
@sekyondaMeta đang làm issue này rồi.
Từ ngày 27/4/2026.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
🚀 Describe the improvement or the new tutorial
Neural Style Transfer utilizes VGG network, which uses maximum pooling.
Although Original article suggests using average pooling instead for better results:
For image synthesis we found that replacing the maximum
pooling operation by average pooling yields slightly more
appealing results, which is why the images shown were generated with average pooling.
This is unsurprising, considering that max pooling may hide gradients of lower layers, while average pooling preserves them, so gradient descent for reconstructing image works better.
I confirm that it actually improves results.
Suggested changes
Replace that:
elif isinstance(layer, nn.MaxPool2d):
name = 'pool_{}'.format(i)
with that:
elif isinstance(layer, nn.MaxPool2d):
name = 'pool_{}'.format(i)
layer = nn.AvgPool2d(
kernel_size=layer.kernel_size,
stride=layer.stride,
padding=layer.padding,
ceil_mode=layer.ceil_mode)
Existing tutorials on this topic
https://docs.pytorch.org/tutorials/advanced/neural_style_tutorial.html
Additional context
No response
cc @albanD @jbschlosser
- Ngôn ngữ chính
- Python
- Star
- 9.4k
- Fork
- 4.4k
- Merge trung bình
- 3 ngày 5 giờ
- Pull request đã merge (30 ngày)
- 4
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của pytorch/tutorials
-
Feedback about Datasets & DataLoadersCó thể đã có người làm @hippi345 đã nhận 1 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 2 ngày
-
💡 [REQUEST] - Add model.eval() after loading the mdoelCó thể đã có người làm @Justee21 đã nhận 25 ngày trước. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 2 ngày
-
[BUG] Captum tutorial fails when visualize_image_attr() receives None for original_imageCó thể làm lại được @shubhambhar007 đã nhận 31 ngày trước và không có pull request nào đang mở. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
pytorch/tutorials#3963 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
[BUG] - Incorrect ResNet18 preprocessing in Captum tutorialCó thể đã có người làm @austxu đã nhận 84 ngày trước. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 2 ngày
-
Feedback about What is torch.nn really?Có thể đã có người làm @MichelleHan7 đã nhận 21 ngày trước. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 2 ngày
Tất cả issue của pytorch/tutorials
Issue tương tự
-
Questions crashes on a real SQuAD2 no-answer predictionCó thể đã có người làm @HuaTNA đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
GST is read as Gulf Standard Time (UTC+4) instead of Guam Standard Time (UTC+10)Có thể đã có người làm @yang00333 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
DOI-USGS/dataretrieval-python#454 ·
Maintainer thường phản hồi trong vòng 4 ngày
-
area:core-platform effort:S priority:P3 status:in-review type:test
Độ khó 2/5 Dưới một giờ Mức phù hợp với người mới 80/100
randomparity/kdive#3246 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Requantification library converts m/z to mass with the hydrogen-atom mass instead of the proton massĐang mởbug
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
nf-core/metaboigniter#130 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
netbox status: needs owner type: documentation
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
netbox-community/netbox#23412 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày