在 Python 中读取 .mat 文件 [英] Read .mat files in Python

查看:35
本文介绍了在 Python 中读取 .mat 文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在 Python 中读取二进制 MATLAB .mat 文件?

Is it possible to read binary MATLAB .mat files in Python?

我已经看到 SciPy 声称支持读取 .mat 文件,但我没有成功.我安装了 SciPy 0.7.0 版,但找不到 loadmat() 方法.

I've seen that SciPy has alleged support for reading .mat files, but I'm unsuccessful with it. I installed SciPy version 0.7.0, and I can't find the loadmat() method.

推荐答案

需要导入,import scipy.io...

import scipy.io
mat = scipy.io.loadmat('file.mat')

这篇关于在 Python 中读取 .mat 文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆