class_docstr: An optimized version of the S3 Artifact Repository.
  
  This class is used for uploading and downloading S3 artifacts for UC models. While it largely
  copies the behavior of the S3ArtifactRepository, the `log_artifact`, `log_artifacts`, and
  `_download_file` methods are optimized by replacing boto3 client operations with the use of
  presigned URLs for both uploads and downloads.
class_docstr_tok: ["An","optimized","version","of","the","S3","Artifact","Repository",".","This","class","is","used","for","uploading","and","downloading","S3","artifacts","for","UC","models",".","While","it","largely","copies","the","behavior","of","the","S3ArtifactRepository",",","the","`","log_artifact","`",",","`","log_artifacts","`",",","and","`","_download_file","`","methods","are","optimized","by","replacing","boto3","client","operations","with","the","use","of","presigned","URLs","for","both","uploads","and","downloads","."]
code: def __init__(
      self,
      artifact_uri,
      access_key_id=None,
      secret_access_key=None,
      session_token=None,
      addressing_style="path",
      s3_endpoint_url=None,
  ):
      super().__init__(artifact_uri)
      self._access_key_id = access_key_id
      self._secret_access_key = secret_access_key
      self._session_token = session_token
      self._addressing_style = addressing_style
      self._s3_endpoint_url = s3_endpoint_url
      self.bucket, self.bucket_path = self.parse_s3_compliant_uri(
          self.artifact_uri
      )
      self._region_name = self._get_region_name()
  
imports: import json
  import logging
  import math
  import os
  import posixpath
  import urllib.parse
  from mimetypes import guess_type
  from mlflow.entities import FileInfo
  from mlflow.environment_variables import MLFLOW_ENABLE_MULTIPART_UPLOAD, MLFLOW_MULTIPART_UPLOAD_CHUNK_SIZE, MLFLOW_S3_UPLOAD_EXTRA_ARGS
  from mlflow.exceptions import MlflowException
  from mlflow.protos.databricks_artifacts_pb2 import ArtifactCredentialInfo
  from mlflow.store.artifact.cloud_artifact_repo import CloudArtifactRepository, _complete_futures
  from mlflow.store.artifact.s3_artifact_repo import _get_s3_client
  from mlflow.utils.file_utils import read_chunk
  from mlflow.utils.request_utils import cloud_storage_http_request
  from mlflow.utils.rest_utils import augmented_raise_for_status
label_desc: Use image node_id 1 to create a new OptimizedS3ArtifactRepository object from inherited base classes: CloudArtifactRepository with example: obj = OptimizedS3ArtifactRepository(artifact_uri, access_key_id, secret_access_key, session_token, addressing_style, s3_endpoint_url)