In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-21 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Suppose we are running an application that requires users to submit a large number of picture files in the application, so it is time-consuming for the system administrator to review these pictures manually, and the review of pictures may not be immediate. To solve this problem, this article will show you how to use Azure Function and Cognitive Services to automate the review of images uploaded to an application.
Before we officially start today's experiment, let's take a look at some of the Azure features that have been reached in this experiment:
L Azure Function:Azure Functions is a serverless computing service that allows you to run code on demand without explicitly configuring or managing the infrastructure. Use Azure Functions to run scripts or code snippets to respond to various events
L Cognitive Services:Azure Cognitive Services are API,SDK and services that help developers build smart applications without direct AI or data science skills or knowledge. Azure Cognitive Services extends Microsoft's growing machine learning API portfolio, enabling developers to easily add cognitive functions-such as emotional and video detection; facial, language and visual recognition; and language and language understanding-into their applications.
L Content Moderator:Azure Content Moderator API is a cognitive service that examines text, images and video content to find materials that may have sex, risk or other undesirable content. When such material is found, the service applies the appropriate label (tag) to the content. Your application can then process the tagged content to comply with regulations or to maintain the user's expected environment.
L Azure Blob Storage:Azure Blob storage is Microsoft's object storage solution for the cloud. Blob storage optimization is used to store large amounts of unstructured data. Unstructured data is data that does not follow a specific data model or definition, such as text or binary data.
Here is the basic topology of our experiment today:
Create Content Moderator
Click "New"-"Content Moderator"-"create":
Enter the relevant information and click create:
After the creation is completed, as shown in the following figure, we click "Show access keys and record this value":
Create Function App and Storage
Create Function App
Click "New"-"calculation"-"Function App":
Enter the following parameters and click create:
Created successfully, as shown in the following figure:
Click "New Function":
Select Custom Function here:
Select "Blob trigger"-"C#":
To modify the name and path, click create:
Created successfully, as shown in the following figure:
Click "Integration"-"+ New output":
Select Azure Blob Storage:
Change the path to "Container1/ {name}" and click Save:
Configure Storage
Create container1 and container2, as shown in the following figure:
Configure Function + Cognitive Services to automatically audit images:
Open the Function we created earlier and click "ImageAnalysis":
Replace the Key that you saved when you created the Content Moderator to the following location:
Click Save:
Test function
Test "invalid" picture:
Upload an "invalid" image to Container1, as shown in the following figure:
After the image has been uploaded, we can see the following Log:
Upload "valid" pictures
Upload a "valid" picture to Container1:
If the upload is successful, you can see the following Log:
At the same time, our images will be watermarked and stored in Container2:
The image with the watermark is shown below:
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.