Main Content

Integrate a Python Package

To integrate a MATLAB® Compiler SDK™ Python® Package:

  1. Install the compiled Python Package.

    See Install a MATLAB Compiler SDK Python Package.

  2. In consultation with the MATLAB programmer, collect the MATLAB function signatures that comprise the services in the application.

  3. Import the compiled Python package.

    See Import Compiled Python Packages.

  4. Write the Python code to initialize the MATLAB Runtime, and load the MATLAB code.

    See Initialize MATLAB Runtime.

  5. Create the required MATLAB data for function inputs and outputs.

    See matlab Python Module.

  6. Invoke the MATLAB functions.

    See Invoke a Packaged MATLAB Function or Invoke a Compiled MATLAB Function Asynchronously.

  7. Terminate each package using its terminate() function. If you do not call this function explicitly, it is called automatically when the program exits.