code: def _unwrap_protocol(path):
      """
      Slice off any protocol prefixes on path.
      """
      if sys.platform == "win32" and _is_local_windows_path(path):
          # Represent as posix path such that downstream functions properly handle it.
          # This is executed when 'file://' is NOT included in the path.
          return pathlib.Path(path).as_posix()
  
      parsed = urllib.parse.urlparse(
          path, allow_fragments=False
      )  # support '#' in path
      query = (
          "?" + parsed.query if parsed.query else ""
      )  # support '?' in path
      netloc = parsed.netloc
      if parsed.scheme == "s3" and "@" in parsed.netloc:
          # If the path contains an @, it is assumed to be an anonymous
          # credentialed path, and we need to strip off the credentials.
          netloc = parsed.netloc.split("@")[-1]
  
      parsed_path = parsed.path
      # urlparse prepends the path with a '/'. This does not work on Windows
      # so if this is the case strip the leading slash.
      if (
          sys.platform == "win32"
          and not netloc
          and len(parsed_path) >= 3
          and parsed_path[0] == "/"  # The problematic leading slash
          and parsed_path[1].isalpha()  # Ensure it is a drive letter.
          and parsed_path[2:4] in (":", ":/")
      ):
          parsed_path = parsed_path[1:]
  
      return netloc + parsed_path + query
  
file_path: ray/python/ray/data/datasource/path_util.py
imports: import pathlib
  import sys
  import urllib
  from typing import TYPE_CHECKING, List, Optional, Tuple, Union
  from ray.data._internal.util import _resolve_custom_scheme
label_desc: Use image node_id 3 for calling a global function with example usage: _unwrap_protocol(path) and returns: unknown, pathlib