Azzera filtri
Azzera filtri

Load symbolic matrix in python

11 visualizzazioni (ultimi 30 giorni)
mikel lasa
mikel lasa il 4 Feb 2022
Risposto: Prasanna Konyala il 1 Apr 2022
Hello,
I have a mat file with a symbolic matrix saved. I would like load this matrix in python, my attempt has been this but it doesnt work:
import scipy.io as sio
mSimbolica = sio.loadmat('D:/TFM/control derivativo/bucle_control/Msimbolica.mat')
mSimbolica
I need help please.
attached the .mat file

Risposte (1)

Prasanna Konyala
Prasanna Konyala il 1 Apr 2022
Hi
From my understanding, you are facing issue when loading mat file in python.
Loading mat files can cause an error if the version is not compatible with SciPy. Please check your mat file version using the following command:
dbtype filename 1
If the output contains Matlab 7.3 then your file is not compatible, and this needs hdf5 python library.
If version is 5.0 or nothing is specified, then your code should work fine.

Prodotti


Release

R2021a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by