class_docstr: Represents a file with a body and an S3 uri.
class_docstr_tok: ["Represents","a","file","with","a","body","and","an","S3","uri","."]
docstr: Save the current instance's body to s3 using the instance's s3 path.
  
  The S3 path can be overridden by providing one. This also overrides the
  default save location for this object.
  
  Args:
      new_save_location_s3_uri (str): Optional. The S3 path to save the file to. If not
          provided, the file is saved in place in S3. If provided, the file's S3 path is
          permanently updated.
  
  Returns:
      str: The s3 location to which the file was saved.
docstr_tok: ["Save","the","current","instance","'s","body","to","s3","using","the","instance","'s","s3","path",".","The","S3","path","can","be","overridden","by","providing","one",".","This","also","overrides","the","default","save","location","for","this","object",".","Args",":","new_save_location_s3_uri","(","str",")",":","Optional",".","The","S3","path","to","save","the","file","to",".","If","not","provided",",","the","file","is","saved","in","place","in","S3",".","If","provided",",","the","file","'s","S3","path","is","permanently","updated",".","Returns",":","str",":","The","s3","location","to","which","the","file","was","saved","."]
code: def save(self, new_save_location_s3_uri=None):
      """Save the current instance's body to s3 using the instance's s3 path.
  
      The S3 path can be overridden by providing one. This also overrides the
      default save location for this object.
  
      Args:
          new_save_location_s3_uri (str): Optional. The S3 path to save the file to. If not
              provided, the file is saved in place in S3. If provided, the file's S3 path is
              permanently updated.
  
      Returns:
          str: The s3 location to which the file was saved.
  
      """
      if new_save_location_s3_uri is not None:
          self.file_s3_uri = new_save_location_s3_uri
  
      return s3.S3Uploader.upload_string_as_file_body(
          body=json.dumps(self.body_dict),
          desired_s3_uri=self.file_s3_uri,
          kms_key=self.kms_key,
          sagemaker_session=self.session,
      )
  
imports: from __future__ import print_function, absolute_import
  import json
  import logging
  import os
  import uuid
  from botocore.exceptions import ClientError
  from sagemaker import s3
  from sagemaker.session import Session
label_desc: Use image node_id 2 for calling the ModelMonitoringFile obj's underlying member method code with example usage: obj.save(new_save_location_s3_uri) and returns: s3