How do I generate code that uses a TensorFlow model without using the TensorFlow library?

I have an existing TensorFlow deep learning network. I would like to use it in code generated from MATLAB, but I do not want the generated code to depend on the TensorFlow library. Do I have any options to achieve this?

 Respuesta aceptada

While you cannot use the TensorFlow model directly in the generated code without introducing a dependency on the TensorFlow library, you can convert your existing network to MATLAB's "dlnetwork" format, and use that in anything you would like to generate code from. The function to convert your network is called "importNetworkFromTensorFlow", and it is documented here:
Note that you will need to install the Deep Learning Toolbox™ Converter for TensorFlow Models Support Package to use this function.
For information and guides on how to generate code from your new "dlnetwork", please see the Deep Learning Code Generation category in our documentation:

Más respuestas (0)

Categorías

Más información sobre Deep Learning Toolbox en Centro de ayuda y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by