vflip¶ torchvision.transforms.functional.vflip(img: Tensor) → Tensor[源代码]¶ 垂直翻转给定图像。 参数: img (PIL Image 或 Tensor) – 要翻转的图像。如果 img 是 Tensor,则预期格式为 […, H, W],其中 … 表示可以有任意数量的前导维度。 返回: 垂直翻转后的图像。 返回类型: PIL 图像或张量 使用 vflip 的示例 转换图示 转换图示