support for new LoadNetwork Layer and support for multiple inputs for Episodic Memory

parent 92c3f290
Pipeline #309782 failed with stage
in 36 seconds
......@@ -183,6 +183,22 @@ public class ArchitectureElementData {
return getLayerSymbol().getStringValue(AllPredefinedLayers.POOL_TYPE_NAME).get();
}
public String getNetworkDir(){
return getLayerSymbol().getStringValue(AllPredefinedLayers.NETWORK_DIR_NAME).get();
}
public String getNetworkPrefix(){
return getLayerSymbol().getStringValue(AllPredefinedLayers.NETWORK_PREFIX_NAME).get();
}
public int getNumInputs(){
return getLayerSymbol().getIntValue(AllPredefinedLayers.NUM_INPUTS_NAME).get();
}
public List<Integer> getOutputShape(){
return getLayerSymbol().getIntTupleValue(AllPredefinedLayers.OUTPUT_SHAPE_NAME).get();
}
public int getScaleFactor(){
return getLayerSymbol().getIntValue(AllPredefinedLayers.SCALE_FACTOR_NAME).get();
}
......@@ -284,7 +300,11 @@ public class ArchitectureElementData {
public String getQueryNetPrefix(){
return getLayerSymbol().getStringValue(AllPredefinedLayers.QUERY_NET_PREFIX_NAME).get();
}
public int getQueryNetNumInputs(){
return getLayerSymbol().getIntValue(AllPredefinedLayers.QUERY_NET_NUM_INPUTS_NAME).get();
}
public int getValuesDim(){
return getLayerSymbol().getIntValue(AllPredefinedLayers.VALUES_DIM_NAME).get();
}
......
......@@ -5,8 +5,8 @@ import de.monticore.lang.monticar.cnnarch._symboltable.*;
import de.monticore.lang.monticar.cnnarch.predefined.Convolution;
import de.monticore.lang.monticar.cnnarch.predefined.FullyConnected;
import de.monticore.lang.monticar.cnnarch.predefined.Pooling;
import de.monticore.lang.monticar.cnnarch.predefined.Memory;
import de.monticore.lang.monticar.cnnarch.predefined.ReplayMemory;
import de.monticore.lang.monticar.cnnarch.predefined.LargeMemory;
import de.monticore.lang.monticar.cnnarch.predefined.EpisodicMemory;
import java.util.*;
......@@ -58,7 +58,7 @@ public class LayerNameCreator {
for (ArchitectureElementSymbol subElement : compositeElement.getElements()){
endStage = name(subElement, endStage, streamIndices);
}
for (List<ArchitectureElementSymbol> subNetwork : compositeElement.getReplaySubNetworks()){
for (List<ArchitectureElementSymbol> subNetwork : compositeElement.getEpisodicSubNetworks()){
for (ArchitectureElementSymbol subElement : subNetwork){
endStage = name(subElement, endStage, streamIndices);
}
......@@ -134,7 +134,7 @@ public class LayerNameCreator {
return "fc";
} else if (layerDeclaration instanceof Pooling) {
return "pool";
} else if (layerDeclaration instanceof Memory || layerDeclaration instanceof ReplayMemory) {
} else if (layerDeclaration instanceof LargeMemory || layerDeclaration instanceof EpisodicMemory) {
return "memory";
} else {
return layerDeclaration.getName().toLowerCase();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment