use of com.yahoo.searchlib.rankingexpression.integration.tensorflow.importer.operations.TensorFlowOperation in project vespa by vespa-engine.
the class TensorFlowImporter method importNode.
private static TensorFlowOperation importNode(String modelName, String nodeName, GraphDef graph, OperationIndex index) {
if (index.alreadyImported(nodeName)) {
return index.get(nodeName);
}
NodeDef node = getTensorFlowNodeFromGraph(namePartOf(nodeName), graph);
List<TensorFlowOperation> inputs = importNodeInputs(modelName, node, graph, index);
TensorFlowOperation operation = OperationMapper.get(modelName, node, inputs, portPartOf(nodeName));
index.put(nodeName, operation);
List<TensorFlowOperation> controlInputs = importControlInputs(modelName, node, graph, index);
if (controlInputs.size() > 0) {
operation.setControlInputs(controlInputs);
}
return operation;
}
Aggregations