Skip to content

Commit

Permalink
Use the propertyname with azureml in priority (Azure#31880)
Browse files Browse the repository at this point in the history
  • Loading branch information
anyalee0221 authored Aug 30, 2023
1 parent 468a956 commit af5e6cb
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions sdk/ml/azure-ai-ml/azure/ai/ml/operations/_job_ops_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@

from azure.ai.ml._artifacts._artifact_utilities import get_datastore_info, list_logs_in_datastore
from azure.ai.ml._restclient.runhistory.models import Run, RunDetails, TypedAssetReference
from azure.ai.ml._restclient.v2022_10_01.models import JobBase
from azure.ai.ml._restclient.v2022_02_01_preview.models import DataType
from azure.ai.ml._restclient.v2022_02_01_preview.models import JobType as RestJobType
from azure.ai.ml._restclient.v2022_02_01_preview.models import ModelType
from azure.ai.ml._restclient.v2022_10_01.models import JobBase
from azure.ai.ml._utils._http_utils import HttpPipeline
from azure.ai.ml._utils.utils import create_requests_pipeline_with_retry, download_text_from_url
from azure.ai.ml.constants._common import GitProperties
Expand Down Expand Up @@ -202,7 +202,21 @@ def stream_logs_until_completion(
studio_endpoint = studio_endpoint.endpoint if studio_endpoint else None
# Feature store jobs should be linked to the Feature Store Workspace UI.
# Todo: Consolidate this logic to service side
if "FeatureStoreJobType" in job_resource.properties.properties:
if "azureml.FeatureStoreJobType" in job_resource.properties.properties:
url_format = (
"https://ml.azure.com/featureStore/{fs_name}/featureSets/{fset_name}/{fset_version}/matJobs/"
"jobs/{run_id}?wsid=/subscriptions/{fs_sub_id}/resourceGroups/{fs_rg_name}/providers/"
"Microsoft.MachineLearningServices/workspaces/{fs_name}"
)
studio_endpoint = url_format.format(
fs_name=job_resource.properties.properties["azureml.FeatureStoreName"],
fs_sub_id=run_operations._subscription_id,
fs_rg_name=run_operations._resource_group_name,
fset_name=job_resource.properties.properties["azureml.FeatureSetName"],
fset_version=job_resource.properties.properties["azureml.FeatureSetVersion"],
run_id=job_name,
)
elif "FeatureStoreJobType" in job_resource.properties.properties:
url_format = (
"https://ml.azure.com/featureStore/{fs_name}/featureSets/{fset_name}/{fset_version}/matJobs/"
"jobs/{run_id}?wsid=/subscriptions/{fs_sub_id}/resourceGroups/{fs_rg_name}/providers/"
Expand Down

0 comments on commit af5e6cb

Please sign in to comment.