(img: Tensor)
return F_pil._get_image_num_channels(img)
Returns number of image channels
Returns number of image channels
Returns number of image channels
def _get_image_num_channels(img: Tensor) -> int:
    """Returns number of image channels
    """
    if isinstance(img, torch.Tensor):
        return F_t._get_image_num_channels(img)

    return F_pil._get_image_num_channels(img)
def _get_image_num_channels ( img : Tensor ) -> int : if isinstance ( img , torch . Tensor ) : return F_t . _get_image_num_channels ( img ) return F_pil . _get_image_num_channels ( img )