Welcome back to the OpenVINO channel
One of the first things to do after you install OpenVINO is to look at code samples that are provided with the package.
You can look at the code, run and play with the samples.
But, There are so many other things you can do with them.
yes, each of these samples is a cool demo
Then you can look at the code and learn how to use the inference engine
You can copy portions of this code to your application, Or you can create you own custom sample..
Just make your changes and compile them.
I'll show you how
The samples are built in a very modular way, So you can specify which input image or video to use
which DL models to use..
So you can use the samples to test your models
or you can use the samples with the pre-trained models provided with OpenVINO.
The validation sample can help you validate your model accuracy on your data-set
The benchmarking utility sample could be used to benchmark performance of models on various platforms and devices.
As always, we first go to the installation directory
And make sure to set our environment is set up
Now, You could find the OpenCV samples and the OpenVX samples in these directories.
These are the OpenCV samples..
And The Inference-Engine samples could be found under inference_engine/samples.
Looking at the directory you can immediately see the available code samples.
Most of the samples here are C++, but there are also some python samples
Now let's build the samples..
I Create a new build directory.. Go there.. Cmake ..
make
And it's running
When it finishes, we'll have all the executables ready for use
In Ubuntu it's under Intel64/Released,
Might be a different location in Windows, but the same principle.
An even better practice is to build the sample in your local directory
So you do not need special permissions, it's all yours.
Here you can change the samples and re-build your own customized ones.
Same way, I'm building a new directory ,
I go there..
cmake
And make..
Now let's try to run one of the samples.
Let's run the security barrier demo for example..
Let's see what are the required parameters.. ..security_barrier_camera_demo -h
Wow.. There are many.. But only 2 are required..
-i .. Input image And -m .. A DL model to use..
Let's do it.
For the input image, I will use the image that is used for this demo..
Car_1.bmp
For the model, I will chose one of the pre-trained models that is provided with the package.
Vehicle-licence-plate-detection-barrier.xml
And it's running..
And you can see that we get the same results as in the demo.
The car and the plate are detected
Now I want to show you how flexible these samples are,
So let's just grab a different image, from the internet..
Make sure it has no copyrights issue..
and Save it to my desktop..
Note that the cars here are pictured from a totally different angle
from a driver seat, Not from a security camera
Now let's re-run the same sample, with a different image..
And we will also use a different model.
This time we will use an ADAS model because the angle of the camera is totally different.
We see the cars from behind and from the side..
Running..
and yes, all the cars are being detected..
So a different image, a different model, Same code.. Same results..
In the same manner, you can plug-in your data-set and your deep learning model and try it out..
More information and documentations..
There are 2 ways to get all the documentation you need..
First one.. Google OpenVINO, go to the page, go to the code-samples..
Here you can see a description per sample.. How to operate, what does it do and so on
The second way is to look at the documentation supplied with the package..
Navigate to the install directory
Go to deployment_tool/ documentation and hit the index
It will open a local web browser.. With all the documents.
Go to samples.. And all the information is there.
How to use, how does the expected result looks like like and so on.
So you now know how to build the samples, how to use them and where to look for documentation.
We will talk more on the samples and the pre-trained models in the coming videos.
Subscribe to the channel and we'll send you a new video each time we have a new feature for OpenVINO.
Thank you.