org.deeplearning4j.nn.api.Layer.getIndex()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(1.9k)|赞(0)|评价(0)|浏览(102)

本文整理了Java中org.deeplearning4j.nn.api.Layer.getIndex()方法的一些代码示例,展示了Layer.getIndex()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Layer.getIndex()方法的具体详情如下:
包路径:org.deeplearning4j.nn.api.Layer
类名称:Layer
方法名:getIndex

Layer.getIndex介绍

[英]Get the layer index.
[中]获取图层索引。

代码示例

代码示例来源:origin: org.deeplearning4j/deeplearning4j-ui-model

private String getSessionID(Model model) {
  if (model instanceof MultiLayerNetwork || model instanceof ComputationGraph)
    return sessionID;
  if (model instanceof Layer) {
    //Keep in mind MultiLayerNetwork implements Layer also...
    Layer l = (Layer) model;
    int layerIdx = l.getIndex();
    return sessionID + "_layer" + layerIdx;
  }
  return sessionID; //Should never happen
}

代码示例来源:origin: org.deeplearning4j/deeplearning4j-nn

@Override
public int getIndex() {
  return insideLayer.getIndex();
}

代码示例来源:origin: org.deeplearning4j/deeplearning4j-nn

protected String layerId() {
  String name = insideLayer.conf().getLayer().getLayerName();
  return "(layer name: " + (name == null ? "\"\"" : name) + ", layer index: " + insideLayer.getIndex() + ")";
}

代码示例来源:origin: org.deeplearning4j/deeplearning4j-nn

int frozenParams = 0;
for (Layer currentLayer : layers) {
  String name = String.valueOf(currentLayer.getIndex());
  String paramShape = "-";
  String in = "-";

代码示例来源:origin: Waikato/wekaDeeplearning4j

next = iter.next();
INDArray features = next.getFeatures();
int layerIdx = model.getLayer(layerName).getIndex() - 1;
Map<String, INDArray> activations = model.feedForward(features, layerIdx, false);
INDArray activationAtLayer = activations.get(layerName);

代码示例来源:origin: neo4j-contrib/neo4j-ml-procedures

for (Layer layer : model.getLayers()) {
  Node node = node("Layer",
      "type", layer.type().name(), "index", layer.getIndex(),
      "pretrainLayer", layer.isPretrainLayer(), "miniBatchSize", layer.getInputMiniBatchSize(),
      "numParams", layer.numParams());

相关文章