diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/_schema/pipeline/pipeline_component.py b/sdk/ml/azure-ai-ml/azure/ai/ml/_schema/pipeline/pipeline_component.py index 240e477dc755..dbd964887aeb 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/_schema/pipeline/pipeline_component.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/_schema/pipeline/pipeline_component.py @@ -72,6 +72,8 @@ def PipelineJobsField(): ], } + # Note: the private node types only available when private preview flag opened before init of pipeline job + # schema class. if is_private_preview_enabled(): pipeline_enable_job_type[ControlFlowType.DO_WHILE] = [NestedField(DoWhileSchema, unknown=INCLUDE)] pipeline_enable_job_type[ControlFlowType.IF_ELSE] = [NestedField(ConditionNodeSchema, unknown=INCLUDE)] diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/condition_node.py b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/condition_node.py index 271031ee6f06..3e8dfc97ea60 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/condition_node.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/condition_node.py @@ -36,6 +36,10 @@ def _create_schema_for_validation( return ConditionNodeSchema(context=context) + @classmethod + def _from_rest_object(cls, obj: dict) -> "ConditionNode": + return cls(**obj) + def _to_dict(self) -> Dict: return self._dump_for_validation() diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/control_flow_node.py b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/control_flow_node.py index 4e1a58492822..f41ecdc13eda 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/control_flow_node.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_builders/control_flow_node.py @@ -67,14 +67,6 @@ def _get_validation_error_target(cls) -> ErrorTarget: """ return ErrorTarget.PIPELINE - @classmethod - def _from_rest_object(cls, obj: dict, reference_node_list: list) -> "ControlFlowNode": - from azure.ai.ml.entities._job.pipeline._load_component import pipeline_node_factory - - node_type = obj.get(CommonYamlFields.TYPE, None) - load_from_rest_obj_func = pipeline_node_factory.get_load_from_rest_object_func(_type=node_type) - return load_from_rest_obj_func(obj, reference_node_list) - class LoopNode(ControlFlowNode, ABC): """ @@ -132,3 +124,11 @@ def _get_data_binding_expression_value(expression, regex): @staticmethod def _is_loop_node_dict(obj): return obj.get(CommonYamlFields.TYPE, None) in [ControlFlowType.DO_WHILE] + + @classmethod + def _from_rest_object(cls, obj: dict, reference_node_list: list) -> "ControlFlowNode": + from azure.ai.ml.entities._job.pipeline._load_component import pipeline_node_factory + + node_type = obj.get(CommonYamlFields.TYPE, None) + load_from_rest_obj_func = pipeline_node_factory.get_load_from_rest_object_func(_type=node_type) + return load_from_rest_obj_func(obj, reference_node_list) diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/_load_component.py b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/_load_component.py index 332ed4255a58..703064e694a1 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/_load_component.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/_load_component.py @@ -17,6 +17,7 @@ from azure.ai.ml.dsl._component_func import to_component_func from azure.ai.ml.dsl._overrides_definition import OverrideDefinition from azure.ai.ml.entities._builders import BaseNode, Command, Import, Parallel, Spark, Sweep +from azure.ai.ml.entities._builders.condition_node import ConditionNode from azure.ai.ml.entities._builders.do_while import DoWhile from azure.ai.ml.entities._builders.pipeline import Pipeline from azure.ai.ml.entities._component.component import Component @@ -81,6 +82,12 @@ def __init__(self): load_from_rest_object_func=DoWhile._from_rest_object, nested_schema=None, ) + self.register_type( + _type=ControlFlowType.IF_ELSE, + create_instance_func=None, + load_from_rest_object_func=ConditionNode._from_rest_object, + nested_schema=None, + ) @classmethod def _get_func(cls, _type: str, funcs): diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/pipeline_job.py b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/pipeline_job.py index ac0dd0fd1e75..59180fa5abfb 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/pipeline_job.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/entities/_job/pipeline/pipeline_job.py @@ -28,6 +28,7 @@ from azure.ai.ml.constants._component import ComponentSource from azure.ai.ml.constants._job.pipeline import ValidationErrorCode from azure.ai.ml.entities._builders import BaseNode +from azure.ai.ml.entities._builders.condition_node import ConditionNode from azure.ai.ml.entities._builders.control_flow_node import LoopNode from azure.ai.ml.entities._builders.import_node import Import from azure.ai.ml.entities._builders.parallel import Parallel @@ -266,11 +267,13 @@ def _customized_validate(self) -> MutableValidationResult: def _validate_input(self): validation_result = self._create_empty_validation_result() + # TODO(1979547): refine this logic: not all nodes have `_get_input_binding_dict` method used_pipeline_inputs = set( itertools.chain( *[ self.component._get_input_binding_dict(node if not isinstance(node, LoopNode) else node.body)[0] - for node in self.jobs.values() + for node in self.jobs.values() if not isinstance(node, ConditionNode) + # condition node has no inputs ] ) ) diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_component_operations.py b/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_component_operations.py index 059dd87731c2..d99513386253 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_component_operations.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_component_operations.py @@ -37,6 +37,7 @@ from .._utils._experimental import experimental from .._utils.utils import is_data_binding_expression +from ..entities._builders.condition_node import ConditionNode from ..entities._component.automl_component import AutoMLComponent from ..entities._component.pipeline_component import PipelineComponent from ._code_operations import CodeOperations @@ -531,6 +532,8 @@ def resolve_base_node(name, node: BaseNode): self._job_operations._resolve_arm_id_for_automl_job(job_instance, resolver, inside_pipeline=True) elif isinstance(job_instance, BaseNode): resolve_base_node(key, job_instance) + elif isinstance(job_instance, ConditionNode): + pass else: msg = f"Non supported job type in Pipeline: {type(job_instance)}" raise ComponentException( diff --git a/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_job_operations.py b/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_job_operations.py index 002c26584486..b237fb7dca08 100644 --- a/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_job_operations.py +++ b/sdk/ml/azure-ai-ml/azure/ai/ml/operations/_job_operations.py @@ -98,6 +98,7 @@ from .._utils._experimental import experimental from ..constants._component import ComponentSource +from ..entities._builders.condition_node import ConditionNode from ..entities._job.pipeline._io import InputOutputBase, _GroupAttrDict, PipelineInput from ._component_operations import ComponentOperations from ._compute_operations import ComputeOperations @@ -419,7 +420,8 @@ def _validate( for node_name, node in job.jobs.items(): try: - if not isinstance(node, DoWhile): + # TODO(1979547): refactor, not all nodes have compute + if not isinstance(node, (DoWhile, ConditionNode)): node.compute = self._try_get_compute_arm_id(node.compute) except Exception as e: # pylint: disable=broad-except validation_result.append_error(yaml_path=f"jobs.{node_name}.compute", message=str(e)) diff --git a/sdk/ml/azure-ai-ml/tests/conftest.py b/sdk/ml/azure-ai-ml/tests/conftest.py index cdcf0f34738f..e6e82d433fb2 100644 --- a/sdk/ml/azure-ai-ml/tests/conftest.py +++ b/sdk/ml/azure-ai-ml/tests/conftest.py @@ -13,9 +13,7 @@ from azure.ai.ml import MLClient, load_component, load_job from azure.ai.ml._restclient.registry_discovery import AzureMachineLearningWorkspaces as ServiceClientRegistryDiscovery from azure.ai.ml._scope_dependent_operations import OperationConfig, OperationScope -from azure.ai.ml._utils._asset_utils import get_object_hash from azure.ai.ml._utils.utils import hash_dict -from azure.ai.ml.constants._common import GitProperties from azure.ai.ml.entities import AzureBlobDatastore, Component from azure.ai.ml.entities._assets import Data, Model from azure.ai.ml.entities._component.parallel_component import ParallelComponent @@ -526,6 +524,7 @@ def credentialless_datastore(client: MLClient, storage_account_name: str) -> Azu def enable_pipeline_private_preview_features(mocker: MockFixture): mocker.patch("azure.ai.ml.entities._job.pipeline.pipeline_job.is_private_preview_enabled", return_value=True) mocker.patch("azure.ai.ml.dsl._pipeline_component_builder.is_private_preview_enabled", return_value=True) + mocker.patch("azure.ai.ml._schema.pipeline.pipeline_component.is_private_preview_enabled", return_value=True) @pytest.fixture() diff --git a/sdk/ml/azure-ai-ml/tests/dsl/e2etests/test_dynamic_pipeline.py b/sdk/ml/azure-ai-ml/tests/dsl/e2etests/test_dynamic_pipeline.py new file mode 100644 index 000000000000..482642095c6a --- /dev/null +++ b/sdk/ml/azure-ai-ml/tests/dsl/e2etests/test_dynamic_pipeline.py @@ -0,0 +1,143 @@ +import contextlib +import pytest + +from azure.ai.ml._schema.pipeline import PipelineJobSchema +from .._util import _DSL_TIMEOUT_SECOND +from test_utilities.utils import _PYTEST_TIMEOUT_METHOD, omit_with_wildcard +from azure.ai.ml._schema.pipeline.pipeline_component import PipelineJobsField +from devtools_testutils import AzureRecordedTestCase + +from azure.ai.ml import MLClient, load_component +from azure.ai.ml.dsl import pipeline +from azure.ai.ml.dsl._condition import condition + + +@contextlib.contextmanager +def include_private_preview_nodes_in_pipeline(): + original_jobs = PipelineJobSchema._declared_fields["jobs"] + PipelineJobSchema._declared_fields["jobs"] = PipelineJobsField() + + try: + yield + finally: + PipelineJobSchema._declared_fields["jobs"] = original_jobs + + +@pytest.mark.usefixtures( + "enable_environment_id_arm_expansion", + "enable_pipeline_private_preview_features", + "mock_code_hash", + "mock_component_hash", + "recorded_test", +) +@pytest.mark.timeout(timeout=_DSL_TIMEOUT_SECOND, method=_PYTEST_TIMEOUT_METHOD) +@pytest.mark.e2etest +class TestDynamicPipeline(AzureRecordedTestCase): + def test_dsl_condition_pipeline(self, client: MLClient): + # update jobs field to include private preview nodes + + hello_world_component_no_paths = load_component( + source="./tests/test_configs/components/helloworld_component_no_paths.yml" + ) + basic_component = load_component( + source="./tests/test_configs/components/component_with_conditional_output/spec.yaml" + ) + + @pipeline( + name="test_mldesigner_component_with_conditional_output", + compute="cpu-cluster", + ) + def condition_pipeline(): + result = basic_component(str_param="abc", int_param=1) + + node1 = hello_world_component_no_paths(component_in_number=1) + node2 = hello_world_component_no_paths(component_in_number=2) + condition(condition=result.outputs.output, false_block=node1, true_block=node2) + + pipeline_job = condition_pipeline() + + # include private preview nodes + with include_private_preview_nodes_in_pipeline(): + pipeline_job = client.jobs.create_or_update(pipeline_job) + + omit_fields = [ + "name", + "properties.display_name", + "properties.jobs.*.componentId", + "properties.settings", + ] + dsl_pipeline_job_dict = omit_with_wildcard(pipeline_job._to_rest_object().as_dict(), *omit_fields) + assert dsl_pipeline_job_dict["properties"]["jobs"] == { + "conditionnode": { + "condition": "${{parent.jobs.result.outputs.output}}", + "false_block": "${{parent.jobs.node1}}", + "true_block": "${{parent.jobs.node2}}", + "type": "if_else", + }, + "node1": { + "_source": "REMOTE.WORKSPACE.COMPONENT", + "computeId": None, + "display_name": None, + "distribution": None, + "environment_variables": {}, + "inputs": {"component_in_number": {"job_input_type": "literal", "value": "1"}}, + "limits": None, + "name": "node1", + "outputs": {}, + "resources": None, + "tags": {}, + "type": "command", + "properties": {}, + }, + "node2": { + "_source": "REMOTE.WORKSPACE.COMPONENT", + "computeId": None, + "display_name": None, + "distribution": None, + "environment_variables": {}, + "inputs": {"component_in_number": {"job_input_type": "literal", "value": "2"}}, + "limits": None, + "name": "node2", + "outputs": {}, + "resources": None, + "tags": {}, + "type": "command", + "properties": {}, + }, + "result": { + "_source": "REMOTE.WORKSPACE.COMPONENT", + "computeId": None, + "display_name": None, + "distribution": None, + "environment_variables": {}, + "inputs": { + "int_param": {"job_input_type": "literal", "value": "1"}, + "str_param": {"job_input_type": "literal", "value": "abc"}, + }, + "limits": None, + "name": "result", + "outputs": {}, + "resources": None, + "tags": {}, + "type": "command", + "properties": {}, + }, + } + + @pytest.mark.skip(reason="TODO(2027778): Verify after primitive condition is supported.") + def test_dsl_condition_pipeline_with_primitive_input(self, client: MLClient): + hello_world_component_no_paths = load_component( + source="./tests/test_configs/components/helloworld_component_no_paths.yml" + ) + + @pipeline( + name="test_mldesigner_component_with_conditional_output", + compute="cpu-cluster", + ) + def condition_pipeline(): + node1 = hello_world_component_no_paths(component_in_number=1) + node2 = hello_world_component_no_paths(component_in_number=2) + condition(condition=True, false_block=node1, true_block=node2) + + pipeline_job = condition_pipeline() + client.jobs.create_or_update(pipeline_job) diff --git a/sdk/ml/azure-ai-ml/tests/recordings/dsl/e2etests/test_dynamic_pipeline.pyTestDynamicPipelinetest_dsl_condition_pipeline.json b/sdk/ml/azure-ai-ml/tests/recordings/dsl/e2etests/test_dynamic_pipeline.pyTestDynamicPipelinetest_dsl_condition_pipeline.json new file mode 100644 index 000000000000..cf864708ee24 --- /dev/null +++ b/sdk/ml/azure-ai-ml/tests/recordings/dsl/e2etests/test_dynamic_pipeline.pyTestDynamicPipelinetest_dsl_condition_pipeline.json @@ -0,0 +1,1220 @@ +{ + "Entries": [ + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/computes/cpu-cluster?api-version=2022-01-01-preview", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:35 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-3a62457354036d3975733586c4f06195-6b507046b5dffa1e-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": [ + "Accept-Encoding", + "Accept-Encoding" + ], + "x-aml-cluster": "vienna-test-westus2-02", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "33a4164b-d2a8-4a09-bce7-c3298431df56", + "x-ms-ratelimit-remaining-subscription-reads": "11997", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094135Z:33a4164b-d2a8-4a09-bce7-c3298431df56", + "x-request-time": "0.242" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/computes/cpu-cluster", + "name": "cpu-cluster", + "type": "Microsoft.MachineLearningServices/workspaces/computes", + "location": "centraluseuap", + "tags": {}, + "properties": { + "createdOn": "2022-09-22T09:02:22.1899959\u002B00:00", + "modifiedOn": "2022-09-23T03:28:18.0066218\u002B00:00", + "disableLocalAuth": false, + "description": null, + "resourceId": null, + "computeType": "AmlCompute", + "computeLocation": "centraluseuap", + "provisioningState": "Succeeded", + "provisioningErrors": null, + "isAttachedCompute": false, + "properties": { + "vmSize": "STANDARD_DS2_V2", + "vmPriority": "Dedicated", + "scaleSettings": { + "maxNodeCount": 4, + "minNodeCount": 1, + "nodeIdleTimeBeforeScaleDown": "PT2M" + }, + "subnet": null, + "currentNodeCount": 1, + "targetNodeCount": 1, + "nodeStateCounts": { + "preparingNodeCount": 0, + "runningNodeCount": 0, + "idleNodeCount": 1, + "unusableNodeCount": 0, + "leavingNodeCount": 0, + "preemptedNodeCount": 0 + }, + "allocationState": "Steady", + "allocationStateTransitionTime": "2022-09-30T08:08:43.647\u002B00:00", + "errors": null, + "remoteLoginPortPublicAccess": "Enabled", + "osType": "Linux", + "virtualMachineImage": null, + "isolatedNetwork": false, + "propertyBag": {} + } + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/datastores/workspaceblobstore?api-version=2022-05-01", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:38 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-b20f3952c8dd86fd0097245b72caca9c-407d850fad24f389-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": [ + "Accept-Encoding", + "Accept-Encoding" + ], + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "82fbd428-e0ab-4648-bd39-bc4a38f601aa", + "x-ms-ratelimit-remaining-subscription-reads": "11996", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094138Z:82fbd428-e0ab-4648-bd39-bc4a38f601aa", + "x-request-time": "0.140" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/datastores/workspaceblobstore", + "name": "workspaceblobstore", + "type": "Microsoft.MachineLearningServices/workspaces/datastores", + "properties": { + "description": null, + "tags": null, + "properties": null, + "isDefault": true, + "credentials": { + "credentialsType": "AccountKey" + }, + "datastoreType": "AzureBlob", + "accountName": "sagvgsoim6nmhbq", + "containerName": "azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8", + "endpoint": "core.windows.net", + "protocol": "https", + "serviceDataAccessAuthIdentity": "WorkspaceSystemAssignedIdentity" + }, + "systemData": { + "createdAt": "2022-09-22T09:02:03.2629568\u002B00:00", + "createdBy": "779301c0-18b2-4cdc-801b-a0a3368fee0a", + "createdByType": "Application", + "lastModifiedAt": "2022-09-22T09:02:04.166989\u002B00:00", + "lastModifiedBy": "779301c0-18b2-4cdc-801b-a0a3368fee0a", + "lastModifiedByType": "Application" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/datastores/workspaceblobstore/listSecrets?api-version=2022-05-01", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "0", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:38 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-64cc4cfe952d60098fd29ccd741a0404-58854ff1cc5f83c2-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": "Accept-Encoding", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "e339b63e-aee3-4eb8-849d-703ab01f940e", + "x-ms-ratelimit-remaining-subscription-writes": "1199", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094139Z:e339b63e-aee3-4eb8-849d-703ab01f940e", + "x-request-time": "0.122" + }, + "ResponseBody": { + "secretsType": "AccountKey", + "key": "dGhpcyBpcyBmYWtlIGtleQ==" + } + }, + { + "RequestUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/LocalUpload/00000000000000000000000000000000/component_with_conditional_output/entry.py", + "RequestMethod": "HEAD", + "RequestHeaders": { + "Accept": "application/xml", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azsdk-python-storage-blob/12.13.1 Python/3.8.13 (Windows-10-10.0.19044-SP0)", + "x-ms-date": "Wed, 12 Oct 2022 09:41:39 GMT", + "x-ms-version": "2021-08-06" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Accept-Ranges": "bytes", + "Content-Length": "594", + "Content-MD5": "42TEgML73MX8PtvISz5yXA==", + "Content-Type": "application/octet-stream", + "Date": "Wed, 12 Oct 2022 09:41:39 GMT", + "ETag": "\u00220x8DAAC352C7174CB\u0022", + "Last-Modified": "Wed, 12 Oct 2022 09:36:00 GMT", + "Server": [ + "Windows-Azure-Blob/1.0", + "Microsoft-HTTPAPI/2.0" + ], + "Vary": "Origin", + "x-ms-access-tier": "Hot", + "x-ms-access-tier-inferred": "true", + "x-ms-blob-type": "BlockBlob", + "x-ms-creation-time": "Wed, 12 Oct 2022 09:36:00 GMT", + "x-ms-lease-state": "available", + "x-ms-lease-status": "unlocked", + "x-ms-meta-name": "2d4b90d4-7558-4353-85be-57180303fd8c", + "x-ms-meta-upload_status": "completed", + "x-ms-meta-version": "1", + "x-ms-server-encrypted": "true", + "x-ms-version": "2021-08-06" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/az-ml-artifacts/00000000000000000000000000000000/component_with_conditional_output/entry.py", + "RequestMethod": "HEAD", + "RequestHeaders": { + "Accept": "application/xml", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azsdk-python-storage-blob/12.13.1 Python/3.8.13 (Windows-10-10.0.19044-SP0)", + "x-ms-date": "Wed, 12 Oct 2022 09:41:40 GMT", + "x-ms-version": "2021-08-06" + }, + "RequestBody": null, + "StatusCode": 404, + "ResponseHeaders": { + "Date": "Wed, 12 Oct 2022 09:41:39 GMT", + "Server": [ + "Windows-Azure-Blob/1.0", + "Microsoft-HTTPAPI/2.0" + ], + "Transfer-Encoding": "chunked", + "Vary": "Origin", + "x-ms-error-code": "BlobNotFound", + "x-ms-version": "2021-08-06" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/2d4b90d4-7558-4353-85be-57180303fd8c/versions/1?api-version=2022-05-01", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "322", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "properties": { + "hash_sha256": "0000000000000", + "hash_version": "0000000000000" + }, + "isAnonymous": true, + "isArchived": false, + "codeUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/LocalUpload/00000000000000000000000000000000/component_with_conditional_output" + } + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:41 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-ab051fafbca223c9b00016975982baf5-917d8697246323e6-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": [ + "Accept-Encoding", + "Accept-Encoding" + ], + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "8cdb0e26-cd5d-46cd-b3c3-2175bc1cbc7c", + "x-ms-ratelimit-remaining-subscription-writes": "1199", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094142Z:8cdb0e26-cd5d-46cd-b3c3-2175bc1cbc7c", + "x-request-time": "0.837" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/2d4b90d4-7558-4353-85be-57180303fd8c/versions/1", + "name": "1", + "type": "Microsoft.MachineLearningServices/workspaces/codes/versions", + "properties": { + "description": null, + "tags": {}, + "properties": { + "hash_sha256": "0000000000000", + "hash_version": "0000000000000" + }, + "isArchived": false, + "isAnonymous": false, + "codeUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/LocalUpload/00000000000000000000000000000000/component_with_conditional_output" + }, + "systemData": { + "createdAt": "2022-10-12T09:36:01.9373145\u002B00:00", + "createdBy": "Han Wang", + "createdByType": "User", + "lastModifiedAt": "2022-10-12T09:41:42.1806471\u002B00:00", + "lastModifiedBy": "Han Wang", + "lastModifiedByType": "User" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/de330be7295a60292e69e4d0aca3cd6b?api-version=2022-05-01", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "379", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "isAnonymous": true, + "isArchived": false, + "condaFile": "channels:\n- defaults\ndependencies:\n- python=3.8.12\n- pip=21.2.2\n- pip:\n - --extra-index-url=https://azuremlsdktestpypi.azureedge.net/sdk-cli-v2\n - mldesigner==0.0.72212755\n - mlflow\n - azureml-mlflow\nname: default_environment\n", + "image": "mcr.microsoft.com/azureml/openmpi3.1.2-ubuntu18.04" + } + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1267", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:44 GMT", + "Expires": "-1", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/de330be7295a60292e69e4d0aca3cd6b?api-version=2022-05-01", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-96a6458be44cec80fec1e16616675cdb-c6405bad94b2d334-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "2b55af11-90c4-4cf1-a603-e3b1baa3d5be", + "x-ms-ratelimit-remaining-subscription-writes": "1198", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094145Z:2b55af11-90c4-4cf1-a603-e3b1baa3d5be", + "x-request-time": "2.235" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/de330be7295a60292e69e4d0aca3cd6b", + "name": "de330be7295a60292e69e4d0aca3cd6b", + "type": "Microsoft.MachineLearningServices/workspaces/environments/versions", + "properties": { + "description": null, + "tags": {}, + "properties": {}, + "isArchived": false, + "isAnonymous": true, + "environmentType": "UserCreated", + "image": "mcr.microsoft.com/azureml/openmpi3.1.2-ubuntu18.04", + "condaFile": "{\n \u0022channels\u0022: [\n \u0022defaults\u0022\n ],\n \u0022dependencies\u0022: [\n \u0022python=3.8.12\u0022,\n \u0022pip=21.2.2\u0022,\n {\n \u0022pip\u0022: [\n \u0022--extra-index-url=https://azuremlsdktestpypi.azureedge.net/sdk-cli-v2\u0022,\n \u0022mldesigner==0.0.72212755\u0022,\n \u0022mlflow\u0022,\n \u0022azureml-mlflow\u0022\n ]\n }\n ],\n \u0022name\u0022: \u0022default_environment\u0022\n}", + "osType": "Linux" + }, + "systemData": { + "createdAt": "2022-10-12T09:36:02.7844653\u002B00:00", + "createdBy": "Han Wang", + "createdByType": "User", + "lastModifiedAt": "2022-10-12T09:36:02.7844653\u002B00:00", + "lastModifiedBy": "Han Wang", + "lastModifiedByType": "User" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/000000000000000000000?api-version=2022-05-01", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "1505", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "description": "module run logic goes here", + "properties": {}, + "tags": { + "codegenBy": "mldesigner" + }, + "isAnonymous": true, + "isArchived": false, + "componentSpec": { + "command": "mldesigner execute --source entry.py --name basic_component --inputs str_param=${{inputs.str_param}} int_param=${{inputs.int_param}} --outputs output1=${{outputs.output1}} output2=${{outputs.output2}} output3=${{outputs.output3}} output=${{outputs.output}}", + "code": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/2d4b90d4-7558-4353-85be-57180303fd8c/versions/1", + "environment": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/de330be7295a60292e69e4d0aca3cd6b", + "name": "azureml_anonymous", + "description": "module run logic goes here", + "tags": { + "codegenBy": "mldesigner" + }, + "version": "000000000000000000000", + "display_name": "basic_component", + "is_deterministic": true, + "inputs": { + "str_param": { + "type": "string" + }, + "int_param": { + "type": "integer" + } + }, + "outputs": { + "output1": { + "type": "boolean", + "mode": "rw_mount", + "is_control": true + }, + "output2": { + "type": "boolean", + "mode": "rw_mount", + "is_control": true + }, + "output3": { + "type": "boolean", + "mode": "rw_mount" + }, + "output": { + "type": "boolean", + "mode": "rw_mount", + "is_control": true + } + }, + "type": "command", + "_source": "YAML.COMPONENT" + } + } + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "2563", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:45 GMT", + "Expires": "-1", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/000000000000000000000?api-version=2022-05-01", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-ccd6124a92c0f0b5d9d71c6a561d17bc-959da80979949cd2-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "b466970a-0907-4f2b-b795-7f8d51e079aa", + "x-ms-ratelimit-remaining-subscription-writes": "1197", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094146Z:b466970a-0907-4f2b-b795-7f8d51e079aa", + "x-request-time": "1.161" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/21dab0f7-4255-4f80-b7fe-3d32c78f7206", + "name": "21dab0f7-4255-4f80-b7fe-3d32c78f7206", + "type": "Microsoft.MachineLearningServices/workspaces/components/versions", + "properties": { + "description": null, + "tags": { + "codegenBy": "mldesigner" + }, + "properties": {}, + "isArchived": false, + "isAnonymous": true, + "componentSpec": { + "name": "azureml_anonymous", + "version": "21dab0f7-4255-4f80-b7fe-3d32c78f7206", + "display_name": "basic_component", + "is_deterministic": "True", + "type": "command", + "description": "module run logic goes here", + "tags": { + "codegenBy": "mldesigner" + }, + "outputs": { + "output1": { + "type": "boolean", + "is_control": "True" + }, + "output2": { + "type": "boolean", + "is_control": "True" + }, + "output3": { + "type": "boolean" + }, + "output": { + "type": "boolean", + "is_control": "True" + } + }, + "inputs": { + "str_param": { + "type": "string", + "optional": "False" + }, + "int_param": { + "type": "integer", + "optional": "False" + } + }, + "code": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/2d4b90d4-7558-4353-85be-57180303fd8c/versions/1", + "environment": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/de330be7295a60292e69e4d0aca3cd6b", + "resources": { + "instance_count": "1" + }, + "command": "mldesigner execute --source entry.py --name basic_component --inputs str_param=${{inputs.str_param}} int_param=${{inputs.int_param}} --outputs output1=${{outputs.output1}} output2=${{outputs.output2}} output3=${{outputs.output3}} output=${{outputs.output}}", + "$schema": "https://componentsdk.azureedge.net/jsonschema/CommandComponent.json" + } + }, + "systemData": { + "createdAt": "2022-10-12T09:36:15.9535083\u002B00:00", + "createdBy": "Han Wang", + "createdByType": "User", + "lastModifiedAt": "2022-10-12T09:36:16.4302604\u002B00:00", + "lastModifiedBy": "Han Wang", + "lastModifiedByType": "User" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/datastores/workspaceblobstore?api-version=2022-05-01", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:46 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-68de7a9843c8e78f8286877f35ec3e25-8800f89ccc96c219-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": [ + "Accept-Encoding", + "Accept-Encoding" + ], + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "c4687228-aab9-4f7b-ab38-8f96248f2984", + "x-ms-ratelimit-remaining-subscription-reads": "11995", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094147Z:c4687228-aab9-4f7b-ab38-8f96248f2984", + "x-request-time": "0.086" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/datastores/workspaceblobstore", + "name": "workspaceblobstore", + "type": "Microsoft.MachineLearningServices/workspaces/datastores", + "properties": { + "description": null, + "tags": null, + "properties": null, + "isDefault": true, + "credentials": { + "credentialsType": "AccountKey" + }, + "datastoreType": "AzureBlob", + "accountName": "sagvgsoim6nmhbq", + "containerName": "azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8", + "endpoint": "core.windows.net", + "protocol": "https", + "serviceDataAccessAuthIdentity": "WorkspaceSystemAssignedIdentity" + }, + "systemData": { + "createdAt": "2022-09-22T09:02:03.2629568\u002B00:00", + "createdBy": "779301c0-18b2-4cdc-801b-a0a3368fee0a", + "createdByType": "Application", + "lastModifiedAt": "2022-09-22T09:02:04.166989\u002B00:00", + "lastModifiedBy": "779301c0-18b2-4cdc-801b-a0a3368fee0a", + "lastModifiedByType": "Application" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/datastores/workspaceblobstore/listSecrets?api-version=2022-05-01", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "0", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:47 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-21a603534db8d1246fbd350c0033a302-1bead72fba3d9296-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": "Accept-Encoding", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "e5c6ab2c-74cd-4cf4-a5dd-71f6ba805cec", + "x-ms-ratelimit-remaining-subscription-writes": "1198", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094148Z:e5c6ab2c-74cd-4cf4-a5dd-71f6ba805cec", + "x-request-time": "0.535" + }, + "ResponseBody": { + "secretsType": "AccountKey", + "key": "dGhpcyBpcyBmYWtlIGtleQ==" + } + }, + { + "RequestUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/LocalUpload/00000000000000000000000000000000/python/sample1.csv", + "RequestMethod": "HEAD", + "RequestHeaders": { + "Accept": "application/xml", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azsdk-python-storage-blob/12.13.1 Python/3.8.13 (Windows-10-10.0.19044-SP0)", + "x-ms-date": "Wed, 12 Oct 2022 09:41:48 GMT", + "x-ms-version": "2021-08-06" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Accept-Ranges": "bytes", + "Content-Length": "508", + "Content-MD5": "dUQjYq1qrTeqLOaZ4N2AUQ==", + "Content-Type": "application/octet-stream", + "Date": "Wed, 12 Oct 2022 09:41:47 GMT", + "ETag": "\u00220x8DA9D482EE600C0\u0022", + "Last-Modified": "Fri, 23 Sep 2022 09:44:17 GMT", + "Server": [ + "Windows-Azure-Blob/1.0", + "Microsoft-HTTPAPI/2.0" + ], + "Vary": "Origin", + "x-ms-access-tier": "Hot", + "x-ms-access-tier-inferred": "true", + "x-ms-blob-type": "BlockBlob", + "x-ms-creation-time": "Fri, 23 Sep 2022 09:44:17 GMT", + "x-ms-lease-state": "available", + "x-ms-lease-status": "unlocked", + "x-ms-meta-name": "92e51c4c-40c7-4f95-ba55-e3a63d7d7c14", + "x-ms-meta-upload_status": "completed", + "x-ms-meta-version": "1", + "x-ms-server-encrypted": "true", + "x-ms-version": "2021-08-06" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/az-ml-artifacts/00000000000000000000000000000000/python/sample1.csv", + "RequestMethod": "HEAD", + "RequestHeaders": { + "Accept": "application/xml", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "User-Agent": "azsdk-python-storage-blob/12.13.1 Python/3.8.13 (Windows-10-10.0.19044-SP0)", + "x-ms-date": "Wed, 12 Oct 2022 09:41:48 GMT", + "x-ms-version": "2021-08-06" + }, + "RequestBody": null, + "StatusCode": 404, + "ResponseHeaders": { + "Date": "Wed, 12 Oct 2022 09:41:48 GMT", + "Server": [ + "Windows-Azure-Blob/1.0", + "Microsoft-HTTPAPI/2.0" + ], + "Transfer-Encoding": "chunked", + "Vary": "Origin", + "x-ms-error-code": "BlobNotFound", + "x-ms-version": "2021-08-06" + }, + "ResponseBody": null + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/92e51c4c-40c7-4f95-ba55-e3a63d7d7c14/versions/1?api-version=2022-05-01", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "295", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "properties": { + "hash_sha256": "0000000000000", + "hash_version": "0000000000000" + }, + "isAnonymous": true, + "isArchived": false, + "codeUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/LocalUpload/00000000000000000000000000000000/python" + } + }, + "StatusCode": 200, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Encoding": "gzip", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:48 GMT", + "Expires": "-1", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-5ee93929dd4f3010f77391fc00288a9a-0dd32d60a5169e04-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "Transfer-Encoding": "chunked", + "Vary": [ + "Accept-Encoding", + "Accept-Encoding" + ], + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "487b75ae-5ab4-4d5b-abd7-ad233749e06c", + "x-ms-ratelimit-remaining-subscription-writes": "1196", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094149Z:487b75ae-5ab4-4d5b-abd7-ad233749e06c", + "x-request-time": "0.171" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/92e51c4c-40c7-4f95-ba55-e3a63d7d7c14/versions/1", + "name": "1", + "type": "Microsoft.MachineLearningServices/workspaces/codes/versions", + "properties": { + "description": null, + "tags": {}, + "properties": { + "hash_sha256": "0000000000000", + "hash_version": "0000000000000" + }, + "isArchived": false, + "isAnonymous": false, + "codeUri": "https://sagvgsoim6nmhbq.blob.core.windows.net/azureml-blobstore-e61cd5e2-512f-475e-9842-5e2a973993b8/LocalUpload/00000000000000000000000000000000/python" + }, + "systemData": { + "createdAt": "2022-09-23T09:44:19.3941658\u002B00:00", + "createdBy": "Ying Chen", + "createdByType": "User", + "lastModifiedAt": "2022-10-12T09:41:49.6451177\u002B00:00", + "lastModifiedBy": "Han Wang", + "lastModifiedByType": "User" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/65a57bb8969551bd51f7d3e2f734e76e?api-version=2022-05-01", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "395", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "isAnonymous": true, + "isArchived": false, + "condaFile": "channels:\n- conda-forge\ndependencies:\n- python=3.7.10\n- numpy\n- pip\n- scikit-learn==0.19.1\n- scipy\n- pip:\n - azureml-defaults\n - inference-schema[numpy-support]\n - joblib\n - numpy\n - scikit-learn==0.19.1\n - scipy\nname: sklearn-aks-env\n", + "image": "mcr.microsoft.com/azureml/openmpi3.1.2-ubuntu18.04" + } + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "1324", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:50 GMT", + "Expires": "-1", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/65a57bb8969551bd51f7d3e2f734e76e?api-version=2022-05-01", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-34cedde3e610c63090d48a64fd5bb6f3-cb1644b884fba9ef-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "def3758e-86e3-4704-aa04-c2f41c098f73", + "x-ms-ratelimit-remaining-subscription-writes": "1195", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094151Z:def3758e-86e3-4704-aa04-c2f41c098f73", + "x-request-time": "0.948" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/65a57bb8969551bd51f7d3e2f734e76e", + "name": "65a57bb8969551bd51f7d3e2f734e76e", + "type": "Microsoft.MachineLearningServices/workspaces/environments/versions", + "properties": { + "description": null, + "tags": {}, + "properties": {}, + "isArchived": false, + "isAnonymous": true, + "environmentType": "UserCreated", + "image": "mcr.microsoft.com/azureml/openmpi3.1.2-ubuntu18.04", + "condaFile": "{\n \u0022channels\u0022: [\n \u0022conda-forge\u0022\n ],\n \u0022dependencies\u0022: [\n \u0022python=3.7.10\u0022,\n \u0022numpy\u0022,\n \u0022pip\u0022,\n \u0022scikit-learn==0.19.1\u0022,\n \u0022scipy\u0022,\n {\n \u0022pip\u0022: [\n \u0022azureml-defaults\u0022,\n \u0022inference-schema[numpy-support]\u0022,\n \u0022joblib\u0022,\n \u0022numpy\u0022,\n \u0022scikit-learn==0.19.1\u0022,\n \u0022scipy\u0022\n ]\n }\n ],\n \u0022name\u0022: \u0022sklearn-aks-env\u0022\n}", + "osType": "Linux" + }, + "systemData": { + "createdAt": "2022-09-23T09:44:21.7120045\u002B00:00", + "createdBy": "Ying Chen", + "createdByType": "User", + "lastModifiedAt": "2022-09-23T09:44:21.7120045\u002B00:00", + "lastModifiedBy": "Ying Chen", + "lastModifiedByType": "User" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/000000000000000000000?api-version=2022-05-01", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "1202", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "description": "This is the basic command component", + "properties": {}, + "tags": { + "tag": "tagvalue", + "owner": "sdkteam" + }, + "isAnonymous": true, + "isArchived": false, + "componentSpec": { + "command": "echo Hello World \u0026 echo ${{inputs.component_in_number}}", + "code": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/92e51c4c-40c7-4f95-ba55-e3a63d7d7c14/versions/1", + "environment": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/65a57bb8969551bd51f7d3e2f734e76e", + "name": "azureml_anonymous", + "description": "This is the basic command component", + "tags": { + "tag": "tagvalue", + "owner": "sdkteam" + }, + "version": "000000000000000000000", + "$schema": "https://azuremlschemas.azureedge.net/development/commandComponent.schema.json", + "display_name": "CommandComponentBasic", + "is_deterministic": true, + "inputs": { + "component_in_number": { + "type": "number", + "default": "10.99", + "description": "A number" + } + }, + "outputs": {}, + "type": "command", + "_source": "YAML.COMPONENT" + } + } + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "2057", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:51 GMT", + "Expires": "-1", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/000000000000000000000?api-version=2022-05-01", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-dfb9ab3515461cc4bff217c3de818e24-e52232bfc1e23945-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "f74fbd5f-63a0-4b2d-8a3c-6535999cf290", + "x-ms-ratelimit-remaining-subscription-writes": "1194", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094152Z:f74fbd5f-63a0-4b2d-8a3c-6535999cf290", + "x-request-time": "0.384" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/c8512cc6-4b83-48e7-8772-202dec1265ec", + "name": "c8512cc6-4b83-48e7-8772-202dec1265ec", + "type": "Microsoft.MachineLearningServices/workspaces/components/versions", + "properties": { + "description": null, + "tags": { + "tag": "tagvalue", + "owner": "sdkteam" + }, + "properties": {}, + "isArchived": false, + "isAnonymous": true, + "componentSpec": { + "name": "azureml_anonymous", + "version": "c8512cc6-4b83-48e7-8772-202dec1265ec", + "display_name": "CommandComponentBasic", + "is_deterministic": "True", + "type": "command", + "description": "This is the basic command component", + "tags": { + "tag": "tagvalue", + "owner": "sdkteam" + }, + "inputs": { + "component_in_number": { + "type": "number", + "optional": "False", + "default": "10.99", + "description": "A number" + } + }, + "code": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/codes/92e51c4c-40c7-4f95-ba55-e3a63d7d7c14/versions/1", + "environment": "azureml:/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/environments/CliV2AnonymousEnvironment/versions/65a57bb8969551bd51f7d3e2f734e76e", + "resources": { + "instance_count": "1" + }, + "command": "echo Hello World \u0026 echo ${{inputs.component_in_number}}", + "$schema": "https://azuremlschemas.azureedge.net/development/commandComponent.schema.json" + } + }, + "systemData": { + "createdAt": "2022-10-12T02:58:51.2816366\u002B00:00", + "createdBy": "Xingzhi Zhang", + "createdByType": "User", + "lastModifiedAt": "2022-10-12T02:58:51.7649434\u002B00:00", + "lastModifiedBy": "Xingzhi Zhang", + "lastModifiedByType": "User" + } + } + }, + { + "RequestUri": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/jobs/000000000000000000000?api-version=2022-10-01-preview", + "RequestMethod": "PUT", + "RequestHeaders": { + "Accept": "application/json", + "Accept-Encoding": "gzip, deflate", + "Connection": "keep-alive", + "Content-Length": "2312", + "Content-Type": "application/json", + "User-Agent": "azure-ai-ml/1.1.0 azsdk-python-mgmt-machinelearningservices/0.1.0 Python/3.8.13 (Windows-10-10.0.19044-SP0)" + }, + "RequestBody": { + "properties": { + "properties": {}, + "tags": {}, + "computeId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/computes/cpu-cluster", + "displayName": "test_mldesigner_component_with_conditional_output", + "experimentName": "azure-ai-ml", + "isArchived": false, + "jobType": "Pipeline", + "inputs": {}, + "jobs": { + "result": { + "resources": null, + "distribution": null, + "limits": null, + "environment_variables": {}, + "name": "result", + "type": "command", + "display_name": null, + "tags": {}, + "computeId": null, + "inputs": { + "str_param": { + "job_input_type": "literal", + "value": "abc" + }, + "int_param": { + "job_input_type": "literal", + "value": "1" + } + }, + "outputs": {}, + "properties": {}, + "_source": "YAML.COMPONENT", + "componentId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/21dab0f7-4255-4f80-b7fe-3d32c78f7206" + }, + "node1": { + "resources": null, + "distribution": null, + "limits": null, + "environment_variables": {}, + "name": "node1", + "type": "command", + "display_name": null, + "tags": {}, + "computeId": null, + "inputs": { + "component_in_number": { + "job_input_type": "literal", + "value": "1" + } + }, + "outputs": {}, + "properties": {}, + "_source": "YAML.COMPONENT", + "componentId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/c8512cc6-4b83-48e7-8772-202dec1265ec" + }, + "node2": { + "resources": null, + "distribution": null, + "limits": null, + "environment_variables": {}, + "name": "node2", + "type": "command", + "display_name": null, + "tags": {}, + "computeId": null, + "inputs": { + "component_in_number": { + "job_input_type": "literal", + "value": "2" + } + }, + "outputs": {}, + "properties": {}, + "_source": "YAML.COMPONENT", + "componentId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/c8512cc6-4b83-48e7-8772-202dec1265ec" + }, + "conditionnode": { + "type": "if_else", + "condition": "${{parent.jobs.result.outputs.output}}", + "true_block": "${{parent.jobs.node2}}", + "false_block": "${{parent.jobs.node1}}" + } + }, + "outputs": {}, + "settings": { + "_source": "DSL" + } + } + }, + "StatusCode": 201, + "ResponseHeaders": { + "Cache-Control": "no-cache", + "Content-Length": "4762", + "Content-Type": "application/json; charset=utf-8", + "Date": "Wed, 12 Oct 2022 09:41:58 GMT", + "Expires": "-1", + "Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/jobs/000000000000000000000?api-version=2022-10-01-preview", + "Pragma": "no-cache", + "Request-Context": "appId=cid-v1:512cc15a-13b5-415b-bfd0-dce7accb6bb1", + "Server-Timing": "traceparent;desc=\u002200-b10fedbccfaf404ea30b1035e94e53a0-338806d246e8c69b-01\u0022", + "Strict-Transport-Security": "max-age=31536000; includeSubDomains", + "x-aml-cluster": "vienna-test-westus2-01", + "X-Content-Type-Options": "nosniff", + "x-ms-correlation-request-id": "b0338354-ff74-4719-a1ab-a6747b053d89", + "x-ms-ratelimit-remaining-subscription-writes": "1193", + "x-ms-response-type": "standard", + "x-ms-routing-request-id": "JAPANEAST:20221012T094159Z:b0338354-ff74-4719-a1ab-a6747b053d89", + "x-request-time": "2.918" + }, + "ResponseBody": { + "id": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/jobs/000000000000000000000", + "name": "000000000000000000000", + "type": "Microsoft.MachineLearningServices/workspaces/jobs", + "properties": { + "description": null, + "tags": {}, + "properties": { + "azureml.DevPlatv2": "true", + "azureml.runsource": "azureml.PipelineRun", + "runSource": "MFE", + "runType": "HTTP", + "azureml.parameters": "{}", + "azureml.continue_on_step_failure": "False", + "azureml.continue_on_failed_optional_input": "True", + "azureml.defaultComputeName": "cpu-cluster", + "azureml.defaultDataStoreName": "workspaceblobstore", + "azureml.pipelineComponent": "pipelinerun" + }, + "displayName": "test_mldesigner_component_with_conditional_output", + "status": "Preparing", + "experimentName": "azure-ai-ml", + "services": { + "Tracking": { + "jobServiceType": "Tracking", + "port": null, + "endpoint": "azureml://master.api.azureml-test.ms/mlflow/v1.0/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000?", + "status": null, + "errorMessage": null, + "properties": null, + "nodes": null + }, + "Studio": { + "jobServiceType": "Studio", + "port": null, + "endpoint": "https://ml.azure.com/runs/000000000000000000000?wsid=/subscriptions/00000000-0000-0000-0000-000000000/resourcegroups/00000/workspaces/00000", + "status": null, + "errorMessage": null, + "properties": null, + "nodes": null + } + }, + "computeId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/computes/cpu-cluster", + "isArchived": false, + "identity": null, + "componentId": null, + "jobType": "Pipeline", + "settings": { + "_source": "DSL" + }, + "jobs": { + "result": { + "resources": null, + "distribution": null, + "limits": null, + "environment_variables": {}, + "name": "result", + "type": "command", + "display_name": null, + "tags": {}, + "computeId": null, + "inputs": { + "str_param": { + "job_input_type": "literal", + "value": "abc" + }, + "int_param": { + "job_input_type": "literal", + "value": "1" + } + }, + "outputs": {}, + "properties": {}, + "_source": "YAML.COMPONENT", + "componentId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/21dab0f7-4255-4f80-b7fe-3d32c78f7206" + }, + "node1": { + "resources": null, + "distribution": null, + "limits": null, + "environment_variables": {}, + "name": "node1", + "type": "command", + "display_name": null, + "tags": {}, + "computeId": null, + "inputs": { + "component_in_number": { + "job_input_type": "literal", + "value": "1" + } + }, + "outputs": {}, + "properties": {}, + "_source": "YAML.COMPONENT", + "componentId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/c8512cc6-4b83-48e7-8772-202dec1265ec" + }, + "node2": { + "resources": null, + "distribution": null, + "limits": null, + "environment_variables": {}, + "name": "node2", + "type": "command", + "display_name": null, + "tags": {}, + "computeId": null, + "inputs": { + "component_in_number": { + "job_input_type": "literal", + "value": "2" + } + }, + "outputs": {}, + "properties": {}, + "_source": "YAML.COMPONENT", + "componentId": "/subscriptions/00000000-0000-0000-0000-000000000/resourceGroups/00000/providers/Microsoft.MachineLearningServices/workspaces/00000/components/azureml_anonymous/versions/c8512cc6-4b83-48e7-8772-202dec1265ec" + }, + "conditionnode": { + "type": "if_else", + "condition": "${{parent.jobs.result.outputs.output}}", + "true_block": "${{parent.jobs.node2}}", + "false_block": "${{parent.jobs.node1}}" + } + }, + "inputs": {}, + "outputs": {}, + "sourceJobId": null + }, + "systemData": { + "createdAt": "2022-10-12T09:41:58.5487917\u002B00:00", + "createdBy": "Han Wang", + "createdByType": "User" + } + } + } + ], + "Variables": {} +} diff --git a/sdk/ml/azure-ai-ml/tests/test_configs/components/component_with_conditional_output/entry.py b/sdk/ml/azure-ai-ml/tests/test_configs/components/component_with_conditional_output/entry.py new file mode 100644 index 000000000000..780b3b68fa26 --- /dev/null +++ b/sdk/ml/azure-ai-ml/tests/test_configs/components/component_with_conditional_output/entry.py @@ -0,0 +1,16 @@ +# --------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# --------------------------------------------------------- +from mldesigner import Output, command_component + + +@command_component() +def basic_component( + str_param: str, + int_param: int, + output1: Output(type="boolean", is_control=True), + output2: Output(type="boolean", is_control=True), + output3: Output(type="boolean"), +) -> Output(type="boolean", is_control=True): + """module run logic goes here""" + return False diff --git a/sdk/ml/azure-ai-ml/tests/test_configs/components/component_with_conditional_output/spec.yaml b/sdk/ml/azure-ai-ml/tests/test_configs/components/component_with_conditional_output/spec.yaml new file mode 100644 index 000000000000..80595730e51c --- /dev/null +++ b/sdk/ml/azure-ai-ml/tests/test_configs/components/component_with_conditional_output/spec.yaml @@ -0,0 +1,52 @@ +name: basic_component +version: '1' +display_name: basic_component +description: module run logic goes here +type: command +inputs: + str_param: + type: string + int_param: + type: integer +outputs: + output1: + type: boolean + is_control: true + mode: rw_mount + output2: + type: boolean + is_control: true + mode: rw_mount + output3: + type: boolean + mode: rw_mount + output: + type: boolean + is_control: true + mode: rw_mount +command: mldesigner execute --source entry.py --name basic_component --inputs + str_param=${{inputs.str_param}} int_param=${{inputs.int_param}} --outputs + output1=${{outputs.output1}} output2=${{outputs.output2}} output3=${{outputs.output3}} + output=${{outputs.output}} +environment: + name: CliV2AnonymousEnvironment + tags: {} + version: de330be7295a60292e69e4d0aca3cd6b + image: mcr.microsoft.com/azureml/openmpi3.1.2-ubuntu18.04 + conda_file: + name: default_environment + channels: + - defaults + dependencies: + - python=3.8.12 + - pip=21.2.2 + - pip: + - --extra-index-url=https://azuremlsdktestpypi.azureedge.net/sdk-cli-v2 + - mldesigner==0.0.72212755 + - mlflow + - azureml-mlflow +code: ./ +tags: + codegenBy: mldesigner +is_deterministic: true +environment_variables: {} \ No newline at end of file