720 or 600: What Each Size Does in pack_product.py and Why
说明与用途
pack_product.py 脚本生成固定尺寸图像(1280×720 封面,600×600 缩略图),消除跨平台显示问题。
问题
Stickers and digital products often have inconsistent cover and thumbnail images, causing broken listings across platforms.
结果
Consistent, platform‑ready images reduce packaging errors, save upload time, and keep the packaging layer predictable.
工作流
- Write pack_product.py to render covers and thumbnails with Pillow.
- Define cover canvas as 1280×720 (16:9) for landscape slots.
- Define thumbnail canvas as 600×600 for square slots.
- Run command: python pack_product.py my-product "My Product" "A short subtitle" 9.
- Script outputs my-product-cover.jpg, my-product-thumb.jpg, and my-product.zip in _system folder.
- Use the same script for all products to maintain consistency.
- Validate metadata with make_metadata.py for each platform.
- Upload assets to platforms.
证据
I spent an evening re-exporting images at three different sizes before I admitted the problem was not my art, it was that I had no fixed output spec.
It lives in pack_product.py, and it produces exactly two raster files per product: a cover at 1280×720 and a thumbnail at 600×600.
The cover is the landscape image. It appears in marketplace cards, link previews, and the top of your product page.
The thumbnail is the square. It exists because squares and landscapes get used in different places, and a cropped landscape is not a substitute for a real square.
One practical note from running this on a 1 vCPU, 2 GB RAM box: rendering a 1280×720 JPEG with Pillow is cheap, a fraction of a second and a few tens of MB of peak RSS.
- 记录日期: 2026-11-02T00:44:02.431Z