MLOps Blog Series Part 2: Testing robustness of secure machine learning systems


Written by Takuto Higuchi, Product Marketing Manager, Data and AI Marketing


Robustness is the ability of a closed-loop system to tolerate perturbations or anomalies while system parameters are varied over a wide range. There are three essential tests to ensure that the machine learning system is robust in the production environments: unit testing, data and model testing, and integration testing.


Unit testing

Tests are performed on individual components that each have a single function within the bigger system (for example, a function that creates a new feature, a column in a DataFrame, or a function that adds two numbers). We can perform unit tests on individual functions or components; a recommended method for performing unit tests is the Arrange, Act, Assert (AAA) approach:


  1. Arrange: Set up the schema, create object instances, and create test data/inputs.
  2. Act: Execute code, call methods, set properties, and apply inputs to the components to test.
  3. Assert: Check the results, validate (confirm that the outputs received are as expected), and clean (test-related remains).

Data and model testing

It is important to test the integrity of the data and models in operation. Tests can be performed in the MLOps pipeline to validate the integrity of data and the model robustness for training and inference. The following are some general tests that can be performed to validate the integrity of data and the robustness of the models:


Read the full article

0 Replies