Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web.Config #3

Closed
Kadantte opened this issue Sep 2, 2018 · 1 comment
Closed

Web.Config #3

Kadantte opened this issue Sep 2, 2018 · 1 comment

Comments

@Kadantte
Copy link

Kadantte commented Sep 2, 2018

Hello Where can i get my key's to fill this out :

<add key="webpages:Version" value="3.0.0.0" />
<add key="webpages:Enabled" value="false" />
<add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
<add key="ObjectDetectionTrainingKey" value="<your_trainning_key>" />
<add key="ObjectDetectionPredictionKey" value="<your_prediction_key>" />
<add key="ObjectDetectionProjectName" value="<Lida>" />
<add key="ObjectDetectionIterationName" value="<your_iteration>" />
<add key="HandwrittenTextSubscriptionKey" value="<your_key>" />
<add key="HandwrittenTextApiEndpoint" value="<your_endpoint>" />
<add key="AzureWebJobsStorage" value="<your_endpoint>" />
<add key="Sketch2CodeAppFunctionEndPoint" value="<your_endpoint>" />
<add key="Probability" value="30" />
<add key="storageUrl" value="<your_storage_url>" />
<add key="ComputerVisionDelay" value="120" />
@Mephisztoe
Copy link

You need to register an Azure Custom Vision Service for example here: https://azure.microsoft.com/en-us/services/cognitive-services/custom-vision-service. While doing so, you need to configure it for object detection. After that you can obtain its training and prediction key from its settings. Also you need to upload the training images you can find in the models folder of the solution, setup the tags (Button, Label, TextBox, and so on) and identify the tags in at least 15 Images per tag before you can train the model. After you have done so, you get an Iteration. So now you also have a Project Name and an Iteration Name for the config file.

For the HandwrittenText… you need to register an Azure Computer Vision Service for example here: https://azure.microsoft.com/en-us/services/cognitive-services/directory/vision/. From its settings you can retrieve the Subscription Key as well as the endpoint.

For the AzureWebJobsStorage you need an Azure Blob Storage that you can register for example here: https://azure.microsoft.com/de-de/services/storage/blobs/. However, while the sourcecode suggests, it needs an endpoint such as the one you used for the text recognition, for the storage you actually need its connection string that you will get from the access keys page of the blobs' settings.

Here is also a little caveat: In every place the sources access the blob, it assumes that the URL retrieved from the configured endpoint does NOT contain a trailing forward slash ("/") which results in bad URLs in several places. You could fix that by removing the additional slashes in the code.

The Sketch2CodeAppFunctionEndpoint and the corresponding storageurl is something you get when you register a Azure App Function Service. Funny thing is: It is never called throughout the app, but instead its execution is commented out.

Hope these hints give you the right direction.

One thing: At several places, the sources refer to a hardcoded URL such as sketch2code.blob.... which is why the app won't show your images correctly until you either rewire the url to your own or make the code correctly read the settings instead.

Cheers,
Christian.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants