code: def path_is_remote(path, s3=True):
      
      prefixes = ("http://", "https://", "/vsicurl/")
      if s3:
          prefixes += ("s3://", "/vsis3/")
      return path.startswith(prefixes)
docs: Determine whether file path is remote or local.
  
      Parameters
      ----------
      path : path to file
  
      Returns
      -------
      is_remote : bool