code: def is_valid_url(path, url=None, logging=False):
      """
      ## is_valid_url
  
      Checks URL validity by testing its scheme against
      FFmpeg's supported protocols
  
      Parameters:
          path (string): absolute path of FFmpeg binaries
          url (string): URL to be validated
          logging (bool): enables logging for its operations
  
      **Returns:** A boolean value, confirming whether tests passed, or not?.
      """
      if url is None or not (url):
          logger.warning("URL is empty!")
          return False
      # extract URL scheme
      extracted_scheme_url = url.split("://", 1)[0]
      # extract all FFmpeg supported protocols
      protocols = check_output([path, "-hide_banner", "-protocols"])
      splitted = [
          x.decode("utf-8").strip() for x in protocols.split(b"\n")
      ]
      supported_protocols = splitted[
          splitted.index("Output:") + 1 : len(splitted) - 1
      ]
      # rtsp is a demuxer somehow
      supported_protocols += (
          ["rtsp"] if "rtsp" in get_supported_demuxers(path) else []
      )
      # Test and return result whether scheme is supported
      if (
          extracted_scheme_url
          and extracted_scheme_url in supported_protocols
      ):
          logging and logger.debug(
              "URL scheme `{}` is supported by FFmpeg.".format(
                  extracted_scheme_url
              )
          )
          return True
      else:
          logger.warning(
              "URL scheme `{}` isn't supported by FFmpeg!".format(
                  extracted_scheme_url
              )
          )
          return False
  
imports: import os
  import re
  import sys
  import cv2
  import types
  import errno
  import stat
  import shutil
  import importlib
  import requests
  import numpy
  import logging
  import platform
  import socket
  from tqdm import tqdm
  from contextlib import closing
  from pathlib import Path
  from colorlog import ColoredFormatter
  from pkg_resources import parse_version
  from requests.adapters import HTTPAdapter, Retry
  from ..version import __version__
label_desc: Use image node_id 14 for calling a global function with example usage: is_valid_url(path, url, logging) and returns: False, True, False