public class KerasModelImport extends Object
| Constructor and Description |
|---|
KerasModelImport() |
| Modifier and Type | Method and Description |
|---|---|
static ComputationGraph |
importKerasModelAndWeights(InputStream modelHdf5Stream)
Load Keras (Functional API) Model saved using model.save_model(...).
|
static ComputationGraph |
importKerasModelAndWeights(InputStream modelHdf5Stream,
boolean enforceTrainingConfig)
Load Keras (Functional API) Model saved using model.save_model(...).
|
static ComputationGraph |
importKerasModelAndWeights(String modelHdf5Filename)
Load Keras (Functional API) Model saved using model.save_model(...).
|
static ComputationGraph |
importKerasModelAndWeights(String modelHdf5Filename,
boolean enforceTrainingConfig)
Load Keras (Functional API) Model saved using model.save_model(...).
|
static ComputationGraph |
importKerasModelAndWeights(String modelHdf5Filename,
int[] inputShape,
boolean enforceTrainingConfig)
Load Keras (Functional API) Model saved using model.save_model(...).
|
static ComputationGraph |
importKerasModelAndWeights(String modelJsonFilename,
String weightsHdf5Filename)
Load Keras (Functional API) Model for which the configuration and weights were
saved separately using calls to model.to_json() and model.save_weights(...).
|
static ComputationGraph |
importKerasModelAndWeights(String modelJsonFilename,
String weightsHdf5Filename,
boolean enforceTrainingConfig)
Load Keras (Functional API) Model for which the configuration and weights were
saved separately using calls to model.to_json() and model.save_weights(...).
|
static ComputationGraphConfiguration |
importKerasModelConfiguration(String modelJsonFilename)
Load Keras (Functional API) Model for which the configuration was saved
separately using calls to model.to_json() and model.save_weights(...).
|
static ComputationGraphConfiguration |
importKerasModelConfiguration(String modelJsonFilename,
boolean enforceTrainingConfig)
Load Keras (Functional API) Model for which the configuration was saved
separately using calls to model.to_json() and model.save_weights(...).
|
static MultiLayerConfiguration |
importKerasSequentialConfiguration(String modelJsonFilename)
Load Keras Sequential model for which the configuration was saved
separately using calls to model.to_json() and model.save_weights(...).
|
static MultiLayerConfiguration |
importKerasSequentialConfiguration(String modelJsonFilename,
boolean enforceTrainingConfig)
Load Keras Sequential model for which the configuration was saved
separately using calls to model.to_json() and model.save_weights(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(InputStream modelHdf5Stream)
Load Keras Sequential model saved using model.save_model(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(InputStream modelHdf5Stream,
boolean enforceTrainingConfig)
Load Keras Sequential model saved using model.save_model(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(String modelHdf5Filename)
Load Keras Sequential model saved using model.save_model(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(String modelHdf5Filename,
boolean enforceTrainingConfig)
Load Keras Sequential model saved using model.save_model(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(String modelHdf5Filename,
int[] inputShape,
boolean enforceTrainingConfig)
Load Keras Sequential model saved using model.save_model(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(String modelJsonFilename,
String weightsHdf5Filename)
Load Keras Sequential model for which the configuration and weights were
saved separately using calls to model.to_json() and model.save_weights(...).
|
static MultiLayerNetwork |
importKerasSequentialModelAndWeights(String modelJsonFilename,
String weightsHdf5Filename,
boolean enforceTrainingConfig)
Load Keras Sequential model for which the configuration and weights were
saved separately using calls to model.to_json() and model.save_weights(...).
|
public static ComputationGraph importKerasModelAndWeights(InputStream modelHdf5Stream, boolean enforceTrainingConfig) throws IOException, UnsupportedKerasConfigurationException, InvalidKerasConfigurationException
modelHdf5Stream - InputStream containing HDF5 archive storing Keras ModelenforceTrainingConfig - whether to enforce training configuration optionsIOExceptionUnsupportedKerasConfigurationExceptionInvalidKerasConfigurationExceptionComputationGraphpublic static ComputationGraph importKerasModelAndWeights(InputStream modelHdf5Stream) throws IOException, UnsupportedKerasConfigurationException, InvalidKerasConfigurationException
modelHdf5Stream - InputStream containing HDF5 archive storing Keras ModelIOExceptionUnsupportedKerasConfigurationExceptionInvalidKerasConfigurationExceptionComputationGraphpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(InputStream modelHdf5Stream, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelHdf5Stream - InputStream containing HDF5 archive storing Keras Sequential modelenforceTrainingConfig - whether to enforce training configuration optionsIOExceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionComputationGraphpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(InputStream modelHdf5Stream) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelHdf5Stream - InputStream containing HDF5 archive storing Keras Sequential modelIOExceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionComputationGraphpublic static ComputationGraph importKerasModelAndWeights(String modelHdf5Filename, int[] inputShape, boolean enforceTrainingConfig) throws IOException, UnsupportedKerasConfigurationException, InvalidKerasConfigurationException
modelHdf5Filename - path to HDF5 archive storing Keras ModelinputShape - optional input shape for models that come without such (e.g. notop = false models)enforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationException - Invalid Keras configUnsupportedKerasConfigurationException - Unsupported Keras configComputationGraphpublic static ComputationGraph importKerasModelAndWeights(String modelHdf5Filename, boolean enforceTrainingConfig) throws IOException, UnsupportedKerasConfigurationException, InvalidKerasConfigurationException
modelHdf5Filename - path to HDF5 archive storing Keras ModelenforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationException - Invalid Keras configUnsupportedKerasConfigurationException - Unsupported Keras configComputationGraphpublic static ComputationGraph importKerasModelAndWeights(String modelHdf5Filename) throws IOException, UnsupportedKerasConfigurationException, InvalidKerasConfigurationException
modelHdf5Filename - path to HDF5 archive storing Keras ModelIOException - IO exceptionInvalidKerasConfigurationException - Invalid Keras configUnsupportedKerasConfigurationException - Unsupported Keras configComputationGraphpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(String modelHdf5Filename, int[] inputShape, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelHdf5Filename - path to HDF5 archive storing Keras Sequential modelinputShape - optional input shape for models that come without such (e.g. notop = false models)enforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(String modelHdf5Filename, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelHdf5Filename - path to HDF5 archive storing Keras Sequential modelenforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(String modelHdf5Filename) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelHdf5Filename - path to HDF5 archive storing Keras Sequential modelIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkpublic static ComputationGraph importKerasModelAndWeights(String modelJsonFilename, String weightsHdf5Filename, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Model configurationweightsHdf5Filename - path to HDF5 archive storing Keras model weightsenforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionComputationGraphpublic static ComputationGraph importKerasModelAndWeights(String modelJsonFilename, String weightsHdf5Filename) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Model configurationweightsHdf5Filename - path to HDF5 archive storing Keras model weightsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionComputationGraphpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(String modelJsonFilename, String weightsHdf5Filename, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Sequential model configurationweightsHdf5Filename - path to HDF5 archive storing Keras model weightsenforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkpublic static MultiLayerNetwork importKerasSequentialModelAndWeights(String modelJsonFilename, String weightsHdf5Filename) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Sequential model configurationweightsHdf5Filename - path to HDF5 archive storing Keras model weightsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkpublic static ComputationGraphConfiguration importKerasModelConfiguration(String modelJsonFilename, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Model configurationenforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionComputationGraphpublic static ComputationGraphConfiguration importKerasModelConfiguration(String modelJsonFilename) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Model configurationIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionComputationGraphpublic static MultiLayerConfiguration importKerasSequentialConfiguration(String modelJsonFilename, boolean enforceTrainingConfig) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Sequential model configurationenforceTrainingConfig - whether to enforce training configuration optionsIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkpublic static MultiLayerConfiguration importKerasSequentialConfiguration(String modelJsonFilename) throws IOException, InvalidKerasConfigurationException, UnsupportedKerasConfigurationException
modelJsonFilename - path to JSON file storing Keras Sequential model configurationIOException - IO exceptionInvalidKerasConfigurationExceptionUnsupportedKerasConfigurationExceptionMultiLayerNetworkCopyright © 2021. All rights reserved.