Experiment - Export as a model

At this stage, you should have already created several Experiment, executed the related training, and analyzed their results. You should now have selected the Experiment that you consider a success and that suits your needs. The next step is basically to make from this Experiment a ModelVersion that will be stored on your Private registry and ready for deployment.

1. Export as a Model

After having accessed the Experiment want to create a ModelVersion from, you simply need to click on the Export as a Model button:

Export as a Model

Export as a Model

A modal will then open, from this one you have two options:

  • Create a brand new Model and its very first ModelVersion
  • Create a new ModelVersion of an existing Model

📘

Model Versionning System

First of all it is important to have the Picsellia Model Versioning system in mind. Indeed, as is the case for Dataset, a Model on Picsellia is composed of one or several ModelVersion.

The ModelVersion is actually what can be considered as a model in the data science ecosystem as the Model files and all model properties are contained under a ModelVersion.

This Model Versioning system mainly aims at ensuring the model's traceability during its whole lifecycle and potential evolution or improvements.

A. New Model

In case you want to create from the current Experiment a brand new Model and its first ModelVersion, you need to jump into the Create Model tab.

`Model` & `ModelVersion` creation though `Experiment` export

Model & ModelVersion creation through Experiment export

In this modal, you will be requested to first initialize your new Model with a name and a description, then initialize its first ModelVersion with a name and description. The Model and ModelVersion will be created in your Private Registry once the Export button clicked.

A good practice would be to name & describe your Model with the actual purpose of detection and the ModelVersion with more specific details that might be changed in a further version. But name and description conventions are under your responsibility.

B. New ModelVersion

In case the current Experiment needs to be exported as a new ModelVersion of a Model already existing in your Private Registry, you can switch to the Create Model Version tab.

`ModelVersion` of existing `Model` creation though `Experiment` export

ModelVersion of existing Model creation through Experiment export

In this modal, you will be requested to select an existing Model among your Private Registry under which you want to create a new ModelVersion with the current Experiment. Once done, you just need to give a name and description to the new ModelVersion of the selected Model. The ModelVersion will be created in your Private Registry once the Export button clicked.

2.Exported items

It is very important to know that exporting an Experiment as a ModelVersion will obviously create a new ModelVersion in your Private Registry but this new object will have many items that are inherited from its source Experiment.

For more specific details about the Model & ModelVersion structure on Picsellia, you can reach this page.

However please note that if some items are missing in the Experiment, they will simply not be exported and the related item in the exported ModelVersion will be empty, as a summary all items are optional for Experiment as for ModelVersion. Their usage and presence depend on your need and your use of the Picsellia platform.

A. Model Files

The most important item, that defines the ModelVersion itself is the Model file(s).

When exporting an Experiment as a new ModelVersion, Picsellia will simply duplicate all the Artifact related to the Experiment and copy them as Model files attached to the exported ModelVersion.

B.LabelMap

The LabelMap is also inherited to the exported ModelVersion.

To be very precise, the LabelMap is initialized when creating an Experiment thanks to the Label defined during DatasetVersion creation. Then when exporting the Experiment as a new ModelVersion, the LabelMap is inherited from the source Experiment and attached to the created ModelVersion.

The LabelMap of the ModelVersion remains editable but it might compromise the consistency of your ModelVersion.

C.Parameters

The parameters are also inherited from the Experiment to the exported ModelVersion. Basically, there are two main purposes for that.

  • Keep the trace at ModelVersion level of the training parameters used to train the current ModelVersion in the frame of its source Experiment.
  • Have the list of training parameters and their default value prefilled in case the exported ModelVersion is used as Base Architecture of a new Experiment

D.Docker Image

As for the training parameters the Docker Image is also inherited from the Experiment to the exported ModelVersion. Basically, there are again the two main purposes for that.

  • Keep the trace at ModelVersion level of the Docker Image used to train the current ModelVersion in the frame of its source Experiment.
  • Have the Docker Image ready to be used for the training script execution in case the exported ModelVersion is used as Base Architecture of a new Experiment

E.Source Experiment

In order to ensure the structure and consistency of your Computer Vision which aims at creating and operating the best-performing ModelVersion, this is absolutely mandatory to have a very clear view of where your ModelVersion comes from.

This is why, while exporting an Experiment as a ModelVersion of your Private Registry, Picsellia will ensure that from your ModelVersion you are able to retrieve easily the Experiment that gave birth to this ModelVersion.

F.Dataset Versions

For the exact same reasons as for the Source Experiment, from your ModelVersion, you will be able to retrieve easily the DatasetVersion used to train the ModelVersion.