Model Training and Optimization#
Important
Auto-training activates when there are enough annotations, however you may notice a delay (~15-20s) before the job appears, after you have sent the last annotation. This is intentional and prevents jobs from starting too early when you are still actively annotating images.
You can configure and retrain your trained models in the Models screen after entering your project. On the Models’ landing page, you will see all your active models.
Models’ Home Screen#
In the home screen of Models, you can reconfigure parameters for active model(s) by pressing Reconfigure and perform transfer learning (training a new model from the base model) by pressing Train a new model. Each mentioned button invokes a dialog box with the settings.
Reconfigure active model#
On the left hand side of the dialog box, you will find 2 options: Global and project-specific, whose name depends on a project type (e.g. Classification task, Detection task etc.). In both of these options, you will find a number of parameters you can tinker with. For instance:
Batch size - The number of training samples (e.g. annotated images) seen in each iteration of training. Increasing this value will reduce the computation time. However, a larger batch size has higher memory requirements.
Learning rate - The size of step at each iteration while reaching a minimum of a loss function. This parameter controls how fast the model adapts to the problem. Increasing this value may speed up training but may also lead to a suboptimal solution.
Maximum number of training epochs - The number of times an algorithm goes through the entire dataset. Increasing this value causes the results to be more robust but the training time becomes longer.
Image tiling#
Image tiling is available in detection and instance segmentation projects, where you can enable this feature in the configurable parameters accessible by clicking on Reconfigure active model.
Image tiling is a technique used to divide a large digital image into multiple smaller images or so called tiles. Tiling is most effective when dealing with large-scale, high-resolution images, such as satellite imagery and aerial photographs, which often contain minuscule objects of interest.
Train a new model#
In this dialog box, you will see model templates for creating a new model with the focus on accuracy, speed, balance, or custom configuration.
In the Recommended tab:
Accuracy option - produces a more accurate, but slower and larger model
Balance option - produces a model in balance with accuracy and speed
Speed option - produces a faster and smaller, but less accurate model
In the All tab, you can see all available model architectures for training a new model.
When you check Use the latest model configuration box, it will allow you to utilize the most recent model’s configurable parameters for the training. If there hasn’t been any model trained for this architecture previously, the system will default to using its pre-set configurable parameters.
The Set configurations manually box, on the other hand, is an option for those seeking to input custom training parameters, but this is currently only supported for the existing pre-defined architectures. When setting configurations manually, you can also customize the new model by clicking on the Train from scratch box, which ignores the training history and retrains the model from the beginning.
Note
If you would like to train a custom model with exported data from the Intel® Geti™ platform, see this example leveraging PyTorch Lightning.
View model’s version history#
You can also see the versions of your active model by clicking on the show more icon to see the accuracy and the creation date of each model version.
Note
Sometimes, you may notice that the system accepts a model with a lower accuracy than the previous model version. You may think that the selected model with the lower accuracy will perform worse. That is not the case. When the next version of a model is made the platform computes the performance of the new version based on the current dataset and also computes the performance of the old model on that new dataset.
For instance:
Model 1 is trained on simple images and it shows performance of 100%.
After training, active learning suggested more complicated images to annotate.
Model 2 is trained on simple and more complicated images.
The system collects the performances of model 1 and model 2 on the more complicated dataset.
Let’s assume, model 2 yields 90% while model 1 yields 60%. The system will accept model 2 as the latest model.
The model screen will show the history of the models with their respective dataset. In this example, the screen will show that model 1 has 100% performance and model 2 has 90% performance. Rest assured that the latest model performs better based on the latest dataset.
Change active model#
If you have trained a couple of models with different architectures, you can change the active model between these architectures. When you change the active model, the model parameters configuration will be passed from a previously active model to a newly set active model.
If you have not trained any model yet, you can change the configuration that will produce the first model in the Models screen - click on Train model to do so. The Balance (SSD) model is set by default as active model before any training starts.
Model lifecycle#
The Geti model lifecycle streamlines the integration of cutting-edge algorithms while ensuring the platform’s maintainability. This lifecycle categorizes models into four distinct stages: Active, Deprecated, Obsolete and Deleted.
Active Models: These models, designated as Recommended, receive full support. The system automatically selects the default model based on optimal performance across the initial 12 annotated images/frames. This selection process evaluates models for their balance, accuracy, or speed. Additionally, each model in the custom menu displays GFLOPs information, aiding in performance comparison.
Deprecated Models: Tagged for eventual removal, these models are still available for training. They appear exclusively under the All model template tab and are not advised for new training projects. Deprecated models include details about their phase-out status, support termination timeline, and suggestions for alternative models. When existing models enter this stage, you will receive prompts to transition to newer models.
Obsolete Models: Models in this stage either become invisible or unselectable in the model templates list. If you employ obsolete models, you will receive notifications on the Model screen, along with guidance to train with new models. Obsolete models are no longer viable for training or inference purposes.
Deleted Models: These models are no longer available for any training or inference purposes. The binaries of the base model, optimized models generated from the base model, and exportable code are removed from the system. You will only be able to see the statistics that were generated for the model. This functionality can be used to save disk space. Deleting a model cannot be undone.
Models’ Details Screen#
You can view more options for each of your model by simply clicking on the model of your choice. You will see the details for the model version you selected but you can switch between versions any time by clicking on the show more icon in the Model breadcrumbs at the top of the screen.
Upon clicking on the model, you will land in the Optimized models tab from which you can select other tabs:
Model variants - where you can view all your models
Model metrics - where you can view the statistics for your model
Parameters - where you can view hyperparameters your model was trained with
Labels - where you can view labels your model contains
Model variants#
You will see your active model with the following information:
baseline model - the name of the model with which the Intel® Geti™ platform started training
precision - a computer number format that occupies space in computer memory
accuracy - the score of the model (measured in %) that indicates a ratio of correctly predicted observation to the total observations
size - the amount of storage capacity the model consumes
download button - allows you to export the trained model
Below your baseline model, you will see your optimized models. If you do not see any optimized model, it means you have not optimized any model yet. You can optimize a model by clicking on Start optimization.
Start optimization option#
When you click on Start optimization, you will be able to convert your model to OpenVINO. Additionally, you can set the optimization to include:
POT (Post-Training Optimization Tool)
Training dataset#
In the Training dataset tab, you can see which images or video frames are used as part of a given subset. You can see the file information by hovering over the thumbnails and view the images or frames by clicking on the thumbnails.
The training dataset is split into three parts (subsets):
Training subset - the system will train on these items
Validation subset - used during training on which performance and optimization is validated
Testing subset - this subset is used to validate performance after training
By default, the split between these subsets depends on the dataset size. If there are less than 10 images, the split is (1/3, 1/3, 1/3). If there are between 10 and 40 images, the split is (1/2, 1/4, 1/4). If there are over 40 images, the split is (8/10, 1/10, 1/10). Most of the measures in the UI state on which subset they are computed (validation or test subset). In general, the score on a validation subset is higher since that is used to optimize the model.
Important
After training a new model, the subset distribution remains unchanged even if manual modifications are made to the subset distribution in the configuration screen. To ensure that the modified distribution takes effect, it is necessary to adjust the distribution sets prior to training any model.
Model metrics#
You can export all the metrics graphs in a PDF format or individually selected metrics graphs in a PDF or CSV format. To download all metrics graphs, click on Download all graphs in the top right-hand corner of the Model metrics panel. To download an individual graph, click on in the in the top right-hand corner of the graph box.
Configurable parameters#
You will find the same options as in Reconfigure in the home screen of Models with the exception of these parameters to be applied to one specific model you selected.
Supported deep learning models#
The platform currently supports several neural network architectures, each tailored to specific computer vision tasks. The table below provides an overview of the supported tasks, types, and corresponding model architectures.
Computer Vision Task |
Task Types |
Model Architectures Supported |
---|---|---|
Image Classification |
Single label, Multi-label, Hierarchical |
LinearHead x (Mobilenet-V3, EfficientNet-B0) |
Object Detection |
ATSS + MobileNet-V2, SSD + MobileNet-V2, YOLOX + CSPDarkNet |
|
Instance Segmentation |
Counting, Rotated object detection |
|
Semantic Segmentation |
||
Anomaly-based Tasks |
Detection |
Data augmentation#
Data augmentation is a technique used to enhance the diversity of data available for training models without actually collecting new data. This approach involves applying a variety of transformations to the training datasets to mimic the variability encountered in real-world scenarios. These transformations can include rotating, scaling, cropping, and altering the color of images.
For specific details on the augmentations applied to each model in the platform, read this document.