Skip to content

Commit 5bf0b3a

Browse files
committed
Fix typo
python -> Python
1 parent 50ddc5d commit 5bf0b3a

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

articles/machine-learning/how-to-create-component-pipeline-python.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -86,23 +86,23 @@ The image classification task can be split into three steps: prepare data, train
8686
8787
For each component, you need to prepare the following staff:
8888
89-
1. Prepare the python script containing the execution logic
89+
1. Prepare the Python script containing the execution logic
9090
9191
1. Define the interface of the component,
9292
9393
1. Add other metadata of the component, including run-time environment, command to run the component, and etc.
9494
95-
The next section will show create components in two different ways: the first two components using python function and the third component using yaml definition.
95+
The next section will show create components in two different ways: the first two components using Python function and the third component using yaml definition.
9696
9797
### Create the data-preparation component
9898
99-
The first component in this pipeline will convert the compressed data files of `fashion_ds` into two csv files, one for training and the other for scoring. You'll use python function to define this component.
99+
The first component in this pipeline will convert the compressed data files of `fashion_ds` into two csv files, one for training and the other for scoring. You'll use Python function to define this component.
100100

101101
If you're following along with the example in the [AzureML Examples repo](https://github.com/Azure/azureml-examples/tree/main/sdk/python/jobs/pipelines/2e_image_classification_keras_minist_convnet), the source files are already available in `prep/` folder. This folder contains two files to construct the component: `prep_component.py`, which defines the component and `conda.yaml`, which defines the run-time environment of the component.
102102
103-
#### Define component using python function
103+
#### Define component using Python function
104104
105-
By using command_component() function as a decorator, you can easily define the component's interface, metadata and code to execute from a python function. Each decorated Python function will be transformed into a single static specification (YAML) that the pipeline service can process.
105+
By using command_component() function as a decorator, you can easily define the component's interface, metadata and code to execute from a Python function. Each decorated Python function will be transformed into a single static specification (YAML) that the pipeline service can process.
106106

107107
:::code language="python" source="~/azureml-examples-main/sdk/python/jobs/pipelines/2e_image_classification_keras_minist_convnet/prep/prep_component.py":::
108108

@@ -134,7 +134,7 @@ Now, you've prepared all source files for the `Prep Data` component.
134134

135135
### Create the train-model component
136136

137-
In this section, you'll create a component for training the image classification model in the python function like the `Prep Data` component.
137+
In this section, you'll create a component for training the image classification model in the Python function like the `Prep Data` component.
138138
139139
The difference is that since the training logic is more complicated, you can put the original training code in a separate Python file.
140140
@@ -146,9 +146,9 @@ The source files of this component are under `train/` folder in the [AzureML Exa
146146
147147
#### Get a script containing execution logic
148148
149-
The `train.py` file contains a normal python function, which performs the training model logic to train a Keras neural network for image classification. You can find the code [here](https://github.com/Azure/azureml-examples/tree/main/sdk/python/jobs/pipelines/2e_image_classification_keras_minist_convnet/train/train.py).
149+
The `train.py` file contains a normal Python function, which performs the training model logic to train a Keras neural network for image classification. You can find the code [here](https://github.com/Azure/azureml-examples/tree/main/sdk/python/jobs/pipelines/2e_image_classification_keras_minist_convnet/train/train.py).
150150
151-
#### Define component using python function
151+
#### Define component using Python function
152152
153153
After defining the training function successfully, you can use @command_component in Azure Machine Learning SDK v2 to wrap your function as a component, which can be used in AzureML pipelines.
154154
@@ -176,7 +176,7 @@ If you're following along with the example in the [AzureML Examples repo](https:
176176

177177
#### Get a script containing execution logic
178178

179-
The `score.py` file contains a normal python function, which performs the training model logic.
179+
The `score.py` file contains a normal Python function, which performs the training model logic.
180180

181181
:::code language="python" source="~/azureml-examples-main/sdk/python/jobs/pipelines/2e_image_classification_keras_minist_convnet/score/score.py":::
182182

@@ -203,7 +203,7 @@ Now, you've got all source files for score-model component.
203203
204204
## Load components to build pipeline
205205
206-
For prep-data component and train-model component defined by python function, you can import the components just like normal python functions.
206+
For prep-data component and train-model component defined by Python function, you can import the components just like normal Python functions.
207207
208208
In the following code, you import `prepare_data_component()` and `keras_train_component()` function from the `prep_component.py` file under `prep` folder and `train_component` file under `train` folder respectively.
209209
@@ -297,7 +297,7 @@ In the previous section, you have built a pipeline using three components to E2E
297297

298298
[!notebook-python[] (~/azureml-examples-main/sdk/python/jobs/pipelines/2e_image_classification_keras_minist_convnet/image_classification_keras_minist_convnet.ipynb?name=register-component)]
299299

300-
Using `ml_client.components.get()`, you can get a registered component by name and version. Using `ml_client.compoennts.create_or_update()`, you can register a component previously loaded from python function or yaml.
300+
Using `ml_client.components.get()`, you can get a registered component by name and version. Using `ml_client.compoennts.create_or_update()`, you can register a component previously loaded from Python function or yaml.
301301
302302
## Next steps
303303

0 commit comments

Comments
 (0)