def METHOD_NAME(self, training_job_name: Optional[str] = None):
    """Get an unsigned URL for DetailProfiler app hosted on SageMaker.
       For users that are already in SM Studio notebook instance, the method tries to
       get domain id and user profile from the Studio environment. If succeeded, the
       generated URL will direct to SM DetailProfiler app. Otherwise it will direct to
       DetailProfiler landing page on SageMaker console. For non Studio users, the
       URL will direct to the DetailProfiler landing page on SageMaker console.
    Args:
        training_job_name (str): Optional. The name of the training job to pre-load in
            DetailProfiler.
            If not provided, no job will be automatically loaded when the URL is opened.
    Returns:
        str: An unsigned URL for DetailProfiler hosted on SageMaker.
    """
    if self._valid_domain_and_user:
        url = f"https://{self._domain_id}.studio.{self.region}.sagemaker.aws/profiler/default"
        if training_job_name is not None:
            self._validate_job_name(training_job_name)
            url += f"/#!/welcome?profile={training_job_name}"
    else:
        dp = "profiler-landing"
        url = "https://{region}.console.aws.amazon.com/sagemaker/home?region={region}#/{dp}".format(
            region=self.region, dp=dp
        )
    return url