23. ML Models

23.1. Saved ML Models

New application ‘Saved ML models’ is available and this page shows all saved ML Models created by *MATHMODEL_SAVE worker in Workflows.


The saved ML Models page has summary tab which will show the overview page and schema of the model.


ML Info tab in the saved ML Models will show the ‘Raw vs prediction’ , ‘Scores’ and ‘Residuals’ page for the Models.


Predict tab is now available in the saved ML Model where we can predict the targets using inputs and compute inputs using targets.


Curve datasets can be used to create saved ML Models in the page. ML saved models will show curves in the overview page and in the prediction tab.


Two saved ML Models can be compared and information is viewed using right context menu options.


3D scatter plot in saved ML models prediction tab now allows adding of Raw Data to the plot as colored bubbles.


Add Custom charts option is now available in the residual tab when two saved ML Models are compared using context menu option.


Filters are now supported for saved ML Models and the filters added are reflected in the ML records.


In ML Saved Model Predict tab carousel UI indicators are showing the correct names of the rows and also has a label at the top which is a caption showing the current row name

Carousel view


In the side-by-side view if the ‘Color predicted curves by difference with references’ option is enabled in the settings then both curve plots on left & right in this new side-by-side view will be colored by the Euclidean distance


Support for files to be opened on the ML Model page.


In ML Model the changes made in the curves in curve plot (colors for example) will be retained throughout the predict view.


SourceType column in Predict tab where it shows Targets -> inputs and vice versa

Targets -> inputs


ML Models | Predictions made in the Predict tab are now automatically saved to the model


ML Models | Export → ZIP will now export the model JSON and the mfile.pkl into a zip. This ZIP can be uploaded on the AI Models page to re-open the model


The Export option is available in the saved ML Models. The exported file can be uploaded in the AI Models page to reopen the model.


The predicted Inputs and Targets are correctly labeled in saved ML Models.

Targets -> inputs labels


In ML Saved Model - Predict has a new header option called ‘Interactive’, along with other options to append a row and to select the source - Targets or Inputs, for choosing the slider value inputs


In ML Models, Compute Inputs is now disabled for Classifier ML as it is applicable only for regression workers.​


In ML Models, the invalid rows message is now correctly displayed and UI is updated when we upload invalid dataset to ML Model.


In ML saved models, the prediction curves and the Raw/Reference curves can be viewed side by side when the Reference input dataset is available in the worker


In ML saved models, raw data curves can now be colored based on columns.


23.2. Independents and Targets

Independents and Targets in overview summary page under saved ML models now show as list of items with icons and distribution chart is available when we click on them.

Targets and Independents


UI Ml models

New view is available to compare multiple ML Models with different features: 1. Summary with​​ all the important attributes 2. ML Info, which has Raw​ vs Predictions data & Residuals and 3. Prediction tab which will predict for each of the model and generate a predicted data


On comparing multiple ML models, we can see the chosen datasets and its charts getting grouped and colored by the MODEL NAME attribute. ​


The Overview of Summary tab has 2 new buttons Default and Normalized to switch between the datasets.​

Default and Normalized


The Residuals tab in the ML Info tab will now show 3 new charts in the summary category where the Residuals chart (For curve columns) will show a Bar chart while Cross-plot of​ Independents vs Targets and Targets vs Predictions will now show a Scatter Matrix. ​

Residuals tab


The header is colored for all independent columns throughout the plugin. ​

Header


The scatter matrix plots for the cross plot and Targets vs Predictions will now show a Transition button to animate from Scatter matrix to Heatmap. Also, transition buttons for every other chart (bubblechart) is available.​

The scatter matrix plots for the cross plot


In the comparison window of ML Models, Nested table header (with row span and column span) is available to define Raw vs predictions in ML Info tab. ​

Nested table header


In the comparison window of ML Models, Independents and Targets category of Summary tab has new Search input option at the​ top.​ ​ .. thumbnail:: /_images/Images/mlmodelssummarytabsummary.png

title:

Header

Header


In the comparison window of ML Models, Scores tab in ML Info shows the nested table of Prediction scores and can also show based on the selected score type for each.​ ​ .. video:: _static/movies/mlmodelsscorestabs.mp4

width:100%

In the comparison window of ML Models, the Hybrid tab shows a Parallel ​chart of the Inputs on the left and on the right side we can toggle between either a curve or table, of the Targets. In this view, ​​ brushing on the left (Inputs)will update the chart on the right (Targets).​


In the comparison window of ML Models, In the 3D category of Summary tab we can add multiple 3D scatter plot by giving different inputs for xBy, yBy and ZBy.​


Summary tab charts in ML Single model viewer now interact with each other i.e. brushing in inputs chart will highlight target table rows OR target curves (if Targets is switched to curve view) and vice versa. ​ ​


Option to pin IDs within the ID column is now available for all the tables across the ML model viewer​

ID column


In the comparison window of ML Models, Custom charts can be added in the Residuals category of ML Info tab.​



23.3. Saved Math model

A new Math model Polymer strain rate is now available in AI models page. Below screen shots shows us the steps to access and predict values in this Math model.

Polymer Strain rate saved Math model



Predict values.

Predict values



Running Predictions in the saved Model

Running Predictions


ML Models Prediction table will now have a new column called ‘IsValid?’ which will show Valid or Invalid flag for a row based on whether the inputs are valid or duplicate value.​

new column called IsValid?


ML Models will now support dropping of a CSV onto the interactive sliders container and predict data from them.​


New Name column is added to the prediction tab of ML Models which will show as a legend in the predicted curves in the same color as that of the Curve.​


In ML Models, new option is available in the context menu to remove the old predictions from the table.​

Context menu to remove the old predictions


23.4. Settings

ML saved Model has new Settings where the view type can be changed to either Simple or Advanced or Configurable where a permissions table will be shown to select different views to be toggled.


ML Models settings tab has a new setting to decide the X_PREFIX that will be used for input curves and prediction curves.​

X_PREFIX


Added support to ML models for categorical independents (inputs) to be selected in Predict Targets list.​

ML models for categorical independents


Added support in ML Models for multi-curve targets which can now be specified within Settings tab as <Column_YY> which will render the curves in a grid view. ​


New options in Predict tab -> Settings dropdown to show items in carousel, add/remove input curves, add/remove reference curves, color the curves based on difference with reference curves, etc. is available. ​


ML saved models now auto detect the targets/prefixes and show them in the settings tab in the model. ​​

Targets/prefixes


In ML Models, the settings option is displayed after we change the chart type to other types.​

Settings option



Matrix columns

In ML Models, new option called Matrix Columns is added to settings which will be used in Heatmap of the Curveplot.​



23.5. Export Bulk

Bulk Export


Single or multiple ML models can be exported as desired.​


Export as PPT and Export as Word are available for ML models.​

Export as PPT/word


23.6. Ml Model chart options

For ML Math Model without Curve dataset, Prediction of Target columns along with options for viewing of different chart types is available in the Prediction tab. ​


For a non-curve model (say scalar predictions: HIC dataset), the Coefficients tab within the ML Info tab, will now show the coefficients table. ​

Coefficients tab within the ML Info


In ML Models with curve dataset, Predict tab -> Table view has context menu options 1. Set as a reference​ and 2. Set as appearance (colors ) settings for the curves. ​


In the comparison window of ML Models, Summary Tab has new chart types for Independents,​​ Targets and other options in the header. ​


In the comparison window of ML Models, Targets category of Summary tab has options to Switch to Curves and to show Box plots as Merged or Segregated. ​


In the comparison window of ML Models, In the prediction tab, there is a new option shown at the top ‘Select a reference to show difference’. If chosen, the table reformats to show the difference in the prediction values of other models w.r.t the reference and corresponding directed arrows. ​

Select a reference to show difference


If ML Model Viewer with a reference dataset is executed and viewed, the Prediction tab will now show the reference data automatically. Once manual data (for prediction) is added to the table, In 3D scatter, we can see the difference between the points present from reference data, the predicted data and the raw data (added from Settings dropdown) colored by the corresponding source.


Changes made within the ML Model Curve Viewer (i.e. colors or axis changes) are now saved as settings which will be carried over to either Side-by-side view OR Carousel view.


Filters

ML Models header now has a button called Filters which will open the Simlytiks ​​ Filters sidebar view allowing adding/removing filters. Any changes made in this view,​ will re-render the tables in Summary tab, Raw vs Predictions and Charts in Residual tab. ​​ ​



Shared

ML Math model can be shared with and viewed by PUBLIC users to use for prediction.​



Curves

In the predict tab of a ML Model, we can see the predicted curve will show context information about the inputs used on right click as in the case of Curve plot .​



23.7. Library

Polymer strain-rate Predictor is now added to the ML Models library. ​



Added Polymer Eng Stress Strain Predictor as one of the AI models in the library.​

Eng Stress Strain Predictor


New AI model NHTSA NCAP is available in saved ML models page Library.​

NHTSA NCAP



New saved model NHTSA ADVANCED is added to the Library of AI models.​



New AI model called Polymer Classifier is added to the library of ML models page.​

Polymer Classifier



Interactive

The interactive mode which is default in saved ML models will now show the sample predict curves when opened.​

interactive mode



In ML models interactive mode, Predict button will disable the inputs and turn into stop button when clicked where we can stop the prediction and update the changes.​