class_docstr: Scheme wrapper around HttpArtifactRepository for mlflow-artifacts server functionality
code: def resolve_uri(cls, artifact_uri, tracking_uri):
      base_url = "/api/2.0/mlflow-artifacts/artifacts"
  
      track_parse = urlparse(tracking_uri)
  
      uri_parse = urlparse(artifact_uri)
  
      # Check to ensure that a port is present with no hostname
      _validate_port_mapped_to_hostname(uri_parse)
  
      # Check that tracking uri is http or https
      _validate_uri_scheme(track_parse.scheme)
  
      if uri_parse.path == "/":  # root directory; build simple path
          resolved = f"{base_url}{uri_parse.path}"
      elif (
          uri_parse.path == base_url
      ):  # for operations like list artifacts
          resolved = base_url
      else:
          resolved = f"{track_parse.path}/{base_url}/{uri_parse.path}"
      resolved = re.sub("//+", "/", resolved)
  
      resolved_artifacts_uri = urlunparse(
          (
              # scheme
              track_parse.scheme,
              # netloc
              uri_parse.netloc
              if uri_parse.netloc
              else track_parse.netloc,
              # path
              resolved,
              # params
              "",
              # query
              "",
              # fragment
              "",
          )
      )
  
      return resolved_artifacts_uri.replace("///", "/").rstrip("/")
  
file_path: mlflow/mlflow/store/artifact/mlflow_artifacts_repo.py
imports: import re
  from urllib.parse import urlparse, urlunparse
  from mlflow.exceptions import MlflowException
  from mlflow.store.artifact.http_artifact_repo import HttpArtifactRepository
  from mlflow.tracking._tracking_service.utils import get_tracking_uri
label_desc: Use image node_id 2 for calling the MlflowArtifactsRepository obj's underlying member method code with example usage: obj.resolve_uri(cls, artifact_uri, tracking_uri) and returns: resolved_artifacts_uri