I'm using the Custom Vision API and the sample I found out on github / docs included the training and creation of a project. However, I have done the training and creation part online (http://customvision.ai).
Now in order to predict the image, I need project ID.
endpoint.PredictImage(project.Id, testImage);
Where can I get this one from?
I am only interested in using the Prediction API without having to train from my code.
Your thoughts please.
The simplest way to get the project url from the website is to open the project in a browser and look at the URL; the project id is the GUID listed after /projects: customvision.ai/projects/<ProjectID>#/manage
Or you can call TrainingApi.GetProjects() to retrieve a list of ProjectModel objects, and get the project id you need by checking its properties (like Name or Description).
Related
I am using Page Object Model in Robot Framework Test Automation and I am trying to pick up the test data using the page object file name. So I would like to read the file name in which I am currently in.
Is there a way to pick up the file name from login.po.resource so that I can pick up the relevant test data automatically ?
I tried ${SUITE SOURCE} but that would only give me Test Suite Name.
Also tried to define a pythod library with file; But that gives me the library name.
PS: Found a work around. But still need a proper solution.
First time using api-platform and Symfony 4 to create an API interface for a MySQL db.
I'm updating an old search interface for the db for which I need to replicate many of the search options. This includes being able to search on a given field using various matching operators/strategies. e.g. starts with, contains exactly equals, etc.
I've set everything up for the api using Annotations.
The #ApiFilter(SearchFilter::class, properties={"fieldname": "strategy"} annotation on my table class works as designed, but I am limited to one-and-only-one strategy per field. I need to be able to pass the strategy to the api search function in the url. something like:
/api/staff?lastname[start]=dav
or
/api/staff?lastname=david&match=contains
or
/api/staff/lastname/son?searchtype=end
would be fine.
I can't figure out how to set this up. Shockingly, to me anyway, this common requirement doesn't seem to be documented at all.
The file CustomSearchFilter.php located at the repo https://github.com/jordonedavidson/custom_search_filter solves this use-case using the
/api/staff?lastname[start]=dav
syntax.
The file was written by Kévin Dunglas (the author of Api Platform) and is presented with his blessing.
I am new to the plugin development of BimClientServerLib.
I have to create a plugin/service where i just need the 3D view and get all the information, so that if i push some information like simulate Door_1 it should be highlighted in the 3D View.I have used the [BimServerClientLib] to check in the project and retrieve some information like get all levels or get all detectors with existing BimViews as 3D viewer and the BIMServerClientLib as a separate Java service.Also, if i use the BimViews which is in Java script how do i push information with the service in Java.
Have a look at BIMSurfer. Download the project into any server (like tomcat), then navigate to the index.html. They have two examples, local one without a BIMServer and another with a connection to BIMServer.
You can adjust their BIMServer example to load your project and for highlighting a specific element, you can the provided library methods (available on the BIMSurfer github main page).
bimSurfer.setSelection({ids: ["object3", "object2", "object4", "object6"], selected: true });
Goodluck.
Trying to understand how TestNG concatenates method name + group name + description to display on report. I have a test suite which only shows the method name on my TestNG report but then I have other test suites that are concatenating the test description after the method name and displaying that entire string on the report (under the 2nd column after the class name column). I can't figure out what controls this difference.
Does anyone understand how this works and is enabled/disabled in the suite? In this scenario, TestNG is being executed by the Maven Surefire plugin, which as you know, places the emailable report under the "target" directory rather than under "testng-output".
Also, an additional detail I am wondering about is: can the description be altered during the Test method so that the altered description can be shown on the report?
This screenshot shows the favorable display of group and description but I have many other test suites that do not show this information and I want to know how to enable it.
Not sure about the report generated by SureFire, but if you use TestNG without Maven it generates two reports - emailable-report, index. Both display the same data but in different presentation. And we can customize the report content by creating a listener and overriding the default methods.
Refer this post on how to customize the report.
To your first question, it seems old versions of testng (prior to 6.8.1) used to have emailablereporter as its default reporter. Later versions have emailablereporter2 as it's default which doesn't show description. Try specifying listener as below to see descriptions against methods.
<listener class-name="org.testng.reporters.EmailableReporter"></listener>
The description can be altered by implementing IAnnotationTransformer.
I'm need to develop a .NET 3.5 application that imports data from Quickbooks, and I decided to use DNOA to OAuthorize with them. I downloaded the latest available version (4.1.something), took a look around, then create a QuickBooksConsumer following the example of GoogleConsumer. However, there is a problem I cannot seem to solve.
The url of the QuickBooks REST services looks like this:
https://services.intuit.com/sb/{0}/v2/{1}
where:
{0} is the name of the object to get the records of (like, "invoice", or "payment");
{1} is the realmId, i.e. the id of the Company the data is required for
The problem is that I don't see how to do PrepareAuthorizedRequest with such variable urls. The function is not virtual, so I cannot override it in my QuickBooksConsumer.cs. I'm stuck.
Can you please show me the way how to do that?
Thanks in advance!
Authorizing requests to dynamically created URLs should be no problem at all. Just wrap any URL in a MessageReceivingEndpoint and send it through ConsumerBase.PrepareAuthorizedRequest and you're good to go.