Main Content

La traduzione di questa pagina non è aggiornata. Fai clic qui per vedere l'ultima versione in inglese.

Chiamata di MATLAB da Python

Scrivere programmi Python® che lavorano con MATLAB®

L’API di MATLAB Engine per Python fornisce un pacchetto Python per chiamare MATLAB come motore computazionale. L’engine supporta l'implementazione di riferimento (CPython). Per informazioni sulle versioni supportate, vedere Versions of Python Compatible with MATLAB Products by Release (Versioni di Python compatibili con i prodotti di MATLAB per release).

Le applicazioni engine richiedono una versione installata di MATLAB; non è possibile eseguire MATLAB Engine su una macchina che dispone solo del runtime di MATLAB.

Funzioni

espandi tutto

matlab.engine.start_matlabStart MATLAB Engine for Python
matlab.engine.find_matlabFind shared MATLAB sessions to connect to MATLAB Engine for Python
matlab.engine.connect_matlabConnect shared MATLAB session to MATLAB Engine for Python
matlab.engine.shareEngineConvert running MATLAB session to shared session
matlab.engine.engineNameReturn name of shared MATLAB session
matlab.engine.isEngineSharedDetermine if MATLAB session is shared

Classi

espandi tutto

matlab.engine.MatlabEnginePython object using MATLAB as computational engine within Python session
matlab.engine.FutureResultResults of asynchronous call to MATLAB function stored in Python object

Argomenti

Installazione

Come iniziare

Gestione della sessione

Utilizzo del workspace di MATLAB

Scambio e mappatura dei dati

Chiamata delle funzioni di MATLAB

Risoluzione dei problemi

Limitations to MATLAB Engine API for Python

MATLAB Engine API for Python does not support these features.

Troubleshoot MATLAB Errors in Python

When a MATLAB function raises an error, the MATLAB Engine for Python stops the function and catches the exception raised by MATLAB.