matlab call keras depth learning model (built environment)

matlab has no direct call interface tensorflow model, but there are calls keras model interface, advanced packaging and keras is tensorflow version, so you can look at this ...... combining model-based methods and learning-based method to generate a lot more interesting applications.

My computer configuration refer to the previous blog post, in short, is the next window, tensorflow-GPU, there are graphics, python 3.5.

(Configuration: https: //blog.csdn.net/vera__zhang/article/details/78531550)

 

1. Install the python library keras

Version keras library and tensorflow correspond to, otherwise there will be problems, such as my tensorflow version is 1.4.0, corresponding keras is 2.0.8. keras latest version is 2.2.0, the latest version if there will be a variety of bug, nowhere to run the program.

Installation instructions: pip install keras == 2.0.8

2.matlab part

Installation matlab R2017b or later

matlab call keras official document as follows:

https://ww2.mathworks.cn/help/nnet/ref/importkerasnetwork.html

https://ww2.mathworks.cn/help/nnet/ref/importkeraslayers.html

Asked us to install a importKerasNetwork interface, this interface must rely on the Neural Network Toolbox matlab. So first get the Toolbox and then get interface.

Toolbox requirements in matlab R2017b version and above, so to re-install matlab, but convenient installation process will automatically configure the library, so do not specifically download.

Installation importKerasNetwork Interface

Then download importKerasNetwork interface file, download the following address:

https://ww2.mathworks.cn/matlabcentral/fileexchange/64649-neural-network-toolbox-tm--importer-for-tensorflow-keras-models

Download the file named "kerasimporter.mlpkginstall", installation method is to open this file in matlab interface, it can be installed.

After installation, use the command help importKerasNetwork you can view the documents.

 

Configuration is completed this environment, a model calls tutorial below. 9 (1❛ᴗ❛1) 6
 

Guess you like

Origin www.cnblogs.com/jnhs/p/11617372.html
Recommended