Shortcuts

to_grayscale

torchvision.transforms.v2.functional.to_grayscale(inpt: Tensor, num_output_channels: int = 1) Tensor

详情请参见灰度