public class ModelSerializer extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
OLD_UPDATER_BIN |
static String |
UPDATER_BIN |
| Modifier and Type | Method and Description |
|---|---|
static ComputationGraph |
restoreComputationGraph(File file)
Load a computation graph from a file
|
static ComputationGraph |
restoreComputationGraph(InputStream is)
Load a computation graph from a file
|
static ComputationGraph |
restoreComputationGraph(String path) |
static MultiLayerNetwork |
restoreMultiLayerNetwork(File file)
Load a multi layer network
from a file
|
static MultiLayerNetwork |
restoreMultiLayerNetwork(InputStream is)
Load a multi layer network
from a file
|
static MultiLayerNetwork |
restoreMultiLayerNetwork(String path) |
static org.nd4j.linalg.heartbeat.reports.Task |
taskByModel(Model model) |
static void |
writeModel(Model model,
File file,
boolean saveUpdater)
Write a model to a file
|
static void |
writeModel(Model model,
OutputStream stream,
boolean saveUpdater)
Write a model to an output stream
|
static void |
writeModel(Model model,
String path,
boolean saveUpdater)
Write a model to a file path
|
public static final String OLD_UPDATER_BIN
public static final String UPDATER_BIN
public static void writeModel(@NonNull
Model model,
@NonNull
File file,
boolean saveUpdater)
throws IOException
model - the model to writefile - the file to write tosaveUpdater - whether to save the updater or notIOExceptionpublic static void writeModel(@NonNull
Model model,
@NonNull
String path,
boolean saveUpdater)
throws IOException
model - the model to writepath - the path to write tosaveUpdater - whether to save the updater
or notIOExceptionpublic static void writeModel(@NonNull
Model model,
@NonNull
OutputStream stream,
boolean saveUpdater)
throws IOException
model - the model to savestream - the output stream to write tosaveUpdater - whether to save the updater for the model or notIOExceptionpublic static MultiLayerNetwork restoreMultiLayerNetwork(@NonNull File file) throws IOException
file - the file to load fromIOExceptionpublic static MultiLayerNetwork restoreMultiLayerNetwork(@NonNull InputStream is) throws IOException
is - the inputstream to load fromIOExceptionpublic static MultiLayerNetwork restoreMultiLayerNetwork(@NonNull String path) throws IOException
path - IOExceptionpublic static ComputationGraph restoreComputationGraph(@NonNull String path) throws IOException
path - IOExceptionpublic static ComputationGraph restoreComputationGraph(@NonNull InputStream is) throws IOException
is - the inputstream to get the computation graph fromIOExceptionpublic static ComputationGraph restoreComputationGraph(@NonNull File file) throws IOException
file - the file to get the computation graph fromIOExceptionpublic static org.nd4j.linalg.heartbeat.reports.Task taskByModel(Model model)
model - Copyright © 2016. All Rights Reserved.