Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

ModelOp Center provides plugins into common data science development tools such as Jupyter, to allow data scientists to interact with ModelOp Center from their preferred development environment.

Table of Contents

Table of Contents

What’s New in v2.1:

  1. Including “Model Functions” definition feature to “Add Model” wizard.

    1. Inspects the code searching for functions to include as options of the dropdown.

    2. Read “smart comments” and pre-sets functions.

    3. Include help about “Model Functions” and “Smart Tags” in information icon.

  2. Editing existing model.

    1. Basic Model Info.

    2. Model Functions (same way).

    3. Platform summary.

    4. Catches unsaved changes in code before saving.

  3. ModelOp toolbar update.

    1. Get rid of “Model Details” button (it was for debugging purposes).

    2. The “Asset Details” button lets you edit the asset name and repo info.

  4. Include Live Search on the “Load Model” screen.

    1. Allow search by model name

    2. Allow search by tag

  5. Support for external parameterized ModelOp Center base URL.

    1. Environment variable setup.

    2. Parameter in NBextensions config.

    3. Enable CORS support to invoke REST API from Jupyter external host.

    4. Enable external libraries compatibility when running on an custom instance.

    5. Add support for Jupyter versions prior to 5.7.0, incompatibility between jquery 3+ and jquery-ui <1.12

  6. Validating file extension to source code asset filename (when creating model and when editing asset file name)

  7. Visualizing ModelOp Jupyter plugin version in all dialogs

  8. Visual feedback on the attachments file upload status

  9. Support for asset role definition on the attachments (during model creation and during file upload).

  10. Enable plugin for Jupyterhub notebook.

  11. Bug Fixes:

    1. When a model was just created the “submit” screen didn’t show the last changes (the initial commit).

    2. Update local cell metadata when saving a model (to avoid keeping outdated data).

    3. Validate to include only code cells in the model creation

    4. Include the model summary in the ‘Save’ screen.

    5. Updating a model overwrote MOC with the current (modified) local copy. That got fixed on “Model Save”, “Model functions editing”, “Asset button edit”

Using ModelOp Center Jupyter plugin
Status
colourGreen
titlev2.1

Overview

The ModelOp Center (MOC) is flexible on how models are registered so that data scientists can leverage their preferred environments for model creation. In other words it is agnostic to the toolkit used to create the model.

Jupyter (http://jupyter.org/) is a popular tool among data scientists and other users of Python and R for building models. It is an evolution of the IPython project, and provides a Notebook interface similar to that of Mathematica or SAGE. For the purposes of the interaction between ModelOp Center and Jupyter we have the Jupyter plugin available which makes it easier to make some of the most useful operations directly in the user’s IDE of choice, in this case, Jupyter notebook.

Installation and configuration instructions

Include Page
Jupyter Installation plugin installation and configuration instructions
Jupyter Installation plugin installation and configuration instructions

ModelOp specific functions available within Jupyter

Once installed, when the user opens or creates a new Jupyter notebook file, the Jupyter notebook interface is provided with a set of toolbar buttons that interact with ModelOp Center and will be expanded in the sections below.

Registering a new model

Include Page
Registering a model using Jupyter
Registering a model using Jupyter

Opening an existing model

Include Page
Opening an existing model in Jupyter
Opening an existing model in Jupyter

Updating an existing model

There are multiple ways in which a model can be updated, depending on what you are ultimately achieving.

Editing the source code

Image Removed

From the toolbar, click on the “Update current model in ModelOp Center“ icon.

Please make sure the previously select a cell which is part of a model already loaded or created using either of the two options above (Registering a new model / Opening an existing model). The screen prompted will confirm the latest changes worked on the cell code before updating the model. This option copies back the source code of the selected cell into the ModelOp Center.

Image Removed

Updating model metadata fields

Image Removed

From the toolbar, click on the “Edit current model” icon.

Please make sure you previously select the notebook cell with an associated model, and the plugin will prompt you with a screen that allows to change the following:

  1. Edit the Model Information

    1. Change Model Name

    2. Change the model Description

  2. Edit the model functions associated with the primary source code. Please refer to “Registering a new model” section of this guide or here for more details. Please note that in order to avoid versioning conflicts, make sure to save all code modifications as indicated in the step “Editing the source code” above before changing the model functions. This will prevent recently introduced function definitions in the code to be associated before the code itself is synced back to ModelOp Center.

This step also sends ModelOp Center with information of the underlying platform in which this is run (system details, python details and libraries loaded).

Adding attachments

Image Removed

From the toolbar, click on the “Add attachment for existing model” icon.

Please make sure you previously select the notebook cell with an associated model, and the plugin will prompt you with a file browser and a screen to attach selected file to the model in the active cell.

Select the role for the asset to upload or leave blank to be automatically determined by ModelOp Center based on the file type.

Image Removed

Submit model version

Image Removed

From the toolbar, click on the “Submit a model version to ModelOp Center” icon.

Please make sure you previously select the notebook cell with an associated model, and the plugin will prompt you with a screen confirming the last changes made to the model.

This action will submit a version for deploy, creating a deployable model. Note it doesn’t directly deploy the model depending on the active Model Life Cycle (MLC) process associated.
Include Page
Updating an existing model using Jupyter
Updating an existing model using Jupyter

Submit model version

Include Page
Submit model version using Jupyter
Submit model version using Jupyter