mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2026-06-17 04:28:54 +08:00
Image.ANTIALIAS -> Image.Resampling.LANCZOS
Summary: Pillow 10 removed `Image.ANTIALIAS` (the built 10.4.0 wheel raises `AttributeError`). Replace it with `Image.Resampling.LANCZOS`, the documented successor, which is dual-compat across Pillow 9.4.0 / 10.4.0 / 11.3.0 / 12.2.0. This lands cleanly under the current 9.4.0 pin ahead of the fleet pin bump. Pure constant rename, no behavior change. PyTorch3D is Meta-authored OSS (fbcode is the source of truth); this change is exported to github.com/facebookresearch/pytorch3d, where the `ANTIALIAS` -> `Resampling.LANCZOS` modernization is equally valid. Part of the Pillow 9.x -> 10.x migration; see `third-party/pypi/pillow/.agents/migrate-9-to-10.md`. ___ Differential Revision: D108493452 fbshipit-source-id: bb1588e9b2057c6cc27a3d6c382faa4b2ac65f7f
This commit is contained in:
committed by
meta-codesync[bot]
parent
f137c87cf9
commit
7f8a8a142f
@@ -130,7 +130,7 @@ class VideoWriter:
|
||||
# make sure size is divisible by 2
|
||||
resize = tuple([resize[i] + resize[i] % 2 for i in (0, 1)])
|
||||
|
||||
im = im.resize(resize, Image.ANTIALIAS)
|
||||
im = im.resize(resize, Image.Resampling.LANCZOS)
|
||||
im.save(outfile)
|
||||
|
||||
self.frames.append(outfile)
|
||||
|
||||
Reference in New Issue
Block a user