当前位置:网站首页>Tips -- solve the problem of no module named matlab.engine
Tips -- solve the problem of no module named matlab.engine
2022-07-28 17:58:00 【A bone loving cat】
1. Problem description
Use matlab Signal processing is a very comfortable thing , But if we want to use python To call MATLAB The result is not happy ?python It's really called MATLAB The library of , That's it matlab.engine modular , But it will appear when used “No module named 'matlab.engine” The problem of :
This is because matlab The question of support , frequently-used matlab The version corresponds to python The version number is :
- Matlab 2016a The highest support python 3.4
- Matlab 2016b,2017a The highest support python 3.5
- Matlab 2017b The highest support python 3.6
- The rest MATLAB Supported by python The version can be installed in the software installation path ( Take my path )
G:\Program Files\MATLAB\R2017b\extern\engines\python
Medium “setup.py” You can see in the file :
Above, MATLAB 2017b Of setup file , It supports python2.7, 3.4, 3.5, 3.6 edition
2. resolvent
- First of all, make sure that MATLAB Whether the version supports the python edition , If not , Suitable can be installed matlab edition , Or change python Version of .
matlab All versions of the cracked version can be found online , Here we use anaconda As an example to demonstrate how to replace python edition :
The first step is to create a new virtual environment , With python3.6 For example
conda create -n py36 python=3.6
Enter the virtual environment :
activate py36
download nb_conda To give jupyter notebook use
conda install nb_conda
such python3.6 The basic environment will be built , The rest is to install some packages you need
- If MATLAB Version support used python edition , You need to do something to MATLAB And python Just go “ binding ”
First step :“win+R” Input “cmd” Open the command line :
The second step : Change the path to MATLAB The installation path , namely “setup.py” The path of the file :
The third step : Open up our python Environmental Science , Here we take the newly established py36 For example :
Step four : Enter the following commands in turn :
python setup.py build --build-base="builddir" install
python setup.py install --prefix="installdir"
python setup.py build --build-base="builddir" install --prefix="installdir"
python setup.py install --user
And then it's done , We can test it , Find out “matlab.engine” Loading successful :
边栏推荐
- @Detailed explanation of requestmapping
- Point cloud processing - KD tree
- TensorFlow2.0(十一)--理解LSTM网络
- centos8按照docker官网创wordpress+mysql报错解决
- 视频号更像是2.0版的公众号
- Point cloud processing voxel filter
- [C language note sharing] - dynamic memory management malloc, free, calloc, realloc, flexible array
- 视频号从每周2-3场到每天3场
- OpenMV(四)--STM32实现特征检测
- 【无标题】
猜你喜欢

Point cloud processing - KD tree

TensorFlow2.0(十二)--实现简单RNN与LSTM网络

LeetCode--45. 跳跃游戏Ⅱ(贪心)

Leetcode systematic question brushing (II) -- greed, backtracking, recursion

xcode打包ipa配置手动配置证书

Encapsulation, inheritance, polymorphism

2022 IDEA (学生邮箱认证)安装使用教程以及基础配置教程

OpenMV(二)--IDE安装与固件下载

IDEA报错Error running ‘Application‘ Command line is too long解决方案

Collection集合
随机推荐
Collection集合
数字滤波器(二)--最小相位延时系统和全通系统
内部类、常用类
Compilation principle learning notes 2 (Introduction to syntax analysis)
2.1 operator
把MySQL8的数据库备份导入MySQL5版本中
MySQL基本查询和运算符
方法、函数
Xcode packaging IPA configuration manual configuration certificate
Use of multithreading
Point cloud processing -- binary tree
做好视频号需要的特质
[advanced C language] - analyze the storage of micro data in memory [i]
视频号上销量较好的品类
Analysis of Alibaba cloud Tianchi competition questions (in-depth learning) -- Reading Notes 1 -- competition question 1
Electrotechnics self study notes 1.20
mysql5.7压缩包安装教程
Leetcode systematic question brushing (V) -- dynamic programming
Image processing code sorting
这么多开源框架,该用哪个好?