You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/azure-functions/machine-learning-pytorch.md
+6-24Lines changed: 6 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ In this article, you learn how to use Python, PyTorch, and Azure Functions to lo
22
22
## Prerequisites
23
23
24
24
- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?ref=microsoft.com&utm_source=microsoft.com&utm_medium=docs&utm_campaign=visualstudio).
25
-
-[Python 3.7.4](https://www.python.org/downloads/release/python-374/). (Python 3.7.4 and Python 3.6.x are verified with Azure Functions; Python 3.8 and later versions are not yet supported.)
25
+
-[Python 3.7.4 or above](https://www.python.org/downloads/release/python-374/). (Python 3.8.x and Python 3.6.x are also verified with Azure Functions.)
26
26
- The [Azure Functions Core Tools](functions-run-local.md#install-the-azure-functions-core-tools)
27
27
- A code editor such as [Visual Studio Code](https://code.visualstudio.com/)
28
28
@@ -42,7 +42,7 @@ In this article, you learn how to use Python, PyTorch, and Azure Functions to lo
42
42
1. Navigate into the folder and examine its contents.
43
43
44
44
```
45
-
cd functions-pytorch
45
+
cd functions-python-pytorch-tutorial
46
46
```
47
47
48
48
- *start* is your working folder for the tutorial.
@@ -52,20 +52,14 @@ In this article, you learn how to use Python, PyTorch, and Azure Functions to lo
52
52
53
53
## Create and activate a Python virtual environment
54
54
55
-
Navigate to the *start* folder and run the following commands to create and activate a virtual environment named `.venv`. Be sure to use Python 3.7, which is supported by Azure Functions.
55
+
Navigate to the *start* folder and run the following commands to create and activate a virtual environment named `.venv`.
@@ -226,10 +208,10 @@ Installation may take a few minutes, during which time you can proceed with modi
226
208
func start
227
209
```
228
210
229
-
1. In a browser, open the following URL to invoke the function with the URL of a cat image and confirm that the returned JSON classifies the image as a cat.
211
+
1. In a browser, open the following URL to invoke the function with the URL of a Bernese Mountain Dog image and confirm that the returned JSON classifies the image as a Bernese Mountain Dog.
1. Keep the host running because you use it in the next step.
@@ -270,7 +252,7 @@ To test invoking the function endpoint from another web app, there's a simple ap
270
252
271
253
1. Select **Submit** to invoke the function endpoint to classify the image.
272
254
273
-

255
+

274
256
275
257
If the browser reports an error when you submit the image URL, check the terminal in which you're running the function app. If you see an error like "No module found 'PIL'", you may have started the function app in the *start* folder without first activating the virtual environment you created earlier. If you still see errors, run `pip install -r requirements.txt` again with the virtual environment activated and look for errors.
0 commit comments