parameters: (self, ellLayers)
docstring: Appends the ELL representation of the current layer to ellLayers.
docstring_summary: Appends the ELL representation of the current layer to ellLayers.
docstring_tokens: Appends the ELL representation of the current layer to ellLayers .
function: def process(self, ellLayers):
          """Appends the ELL representation of the current layer to ellLayers."""
  
          # Note that a single CNTK Linear function block is equivalent to the following 3 ELL layers:
          # - FullyConnectedLayer
          # - BiasLayer
          # - ActivationLayer. This layer is sometimes missing, depending on activation type.
          #
          # Therefore, make sure the output padding characteristics of the last layer reflect the next layer's
          # padding requirements.
  
          weightsParameter = utilities.find_parameter_by_name(self.layer.parameters, 'W', 0)
          biasParameter = utilities.find_parameter_by_name(self.layer.parameters, 'b', 1)
          weightsTensor = converters.get_tensor_from_cntk_dense_weight_parameter(weightsParameter)
          biasVector = converters.get_vector_from_cntk_trainable_parameter(biasParameter)
  
          # Create the ell.neural.LayerParameters for the various ELL layers
          firstLayerParameters = ell.neural.LayerParameters(
              self.layer.ell_inputShape, self.layer.ell_inputPaddingParameters,
              self.layer.ell_outputShapeMinusPadding, ell.neural.NoPadding(), ell.nodes.PortType.smallReal)
          middleLayerParameters = ell.neural.LayerParameters(self.layer.ell_outputShapeMinusPadding, ell.neural.NoPadding(
          ), self.layer.ell_outputShapeMinusPadding, ell.neural.NoPadding(), ell.nodes.PortType.smallReal)
          lastLayerParameters = ell.neural.LayerParameters(self.layer.ell_outputShapeMinusPadding, ell.neural.NoPadding(
          ), self.layer.ell_outputShape, self.layer.ell_outputPaddingParameters, ell.nodes.PortType.smallReal)
  
          layerParameters = firstLayerParameters
  
          internalNodes = utilities.get_model_layers(self.layer.block_root)
          activationType = utilities.get_ell_activation_type(internalNodes)
  
          # Create the ELL fully connected layer
          ellLayers.append(ell.neural.FullyConnectedLayer(
              layerParameters, weightsTensor))
  
          # Create the ELL bias layer
          isSoftmaxActivation = utilities.is_softmax_activation(internalNodes)
          hasActivation = isSoftmaxActivation or activationType is not None
          if (hasActivation):
              layerParameters = middleLayerParameters
          else:
              layerParameters = lastLayerParameters
          ellLayers.append(ell.neural.BiasLayer(layerParameters, biasVector))
  
          # Create the ELL activation layer
          if (hasActivation):
              layerParameters = lastLayerParameters
  
              # Special case: if this is softmax activation, create an ELL Softmax layer.
              # Else, insert an ELL ActivationLayer
              if (isSoftmaxActivation):
                  ellLayers.append(ell.neural.SoftmaxLayer(layerParameters))
              else:
                  ellLayers.append(ell.neural.ActivationLayer(
                      layerParameters, activationType))
function_tokens: def process ( self , ellLayers ) : # Note that a single CNTK Linear function block is equivalent to the following 3 ELL layers: # - FullyConnectedLayer # - BiasLayer # - ActivationLayer. This layer is sometimes missing, depending on activation type. # # Therefore, make sure the output padding characteristics of the last layer reflect the next layer's # padding requirements. weightsParameter = utilities . find_parameter_by_name ( self . layer . parameters , 'W' , 0 ) biasParameter = utilities . find_parameter_by_name ( self . layer . parameters , 'b' , 1 ) weightsTensor = converters . get_tensor_from_cntk_dense_weight_parameter ( weightsParameter ) biasVector = converters . get_vector_from_cntk_trainable_parameter ( biasParameter ) # Create the ell.neural.LayerParameters for the various ELL layers firstLayerParameters = ell . neural . LayerParameters ( self . layer . ell_inputShape , self . layer . ell_inputPaddingParameters , self . layer . ell_outputShapeMinusPadding , ell . neural . NoPadding ( ) , ell . nodes . PortType . smallReal ) middleLayerParameters = ell . neural . LayerParameters ( self . layer . ell_outputShapeMinusPadding , ell . neural . NoPadding ( ) , self . layer . ell_outputShapeMinusPadding , ell . neural . NoPadding ( ) , ell . nodes . PortType . smallReal ) lastLayerParameters = ell . neural . LayerParameters ( self . layer . ell_outputShapeMinusPadding , ell . neural . NoPadding ( ) , self . layer . ell_outputShape , self . layer . ell_outputPaddingParameters , ell . nodes . PortType . smallReal ) layerParameters = firstLayerParameters internalNodes = utilities . get_model_layers ( self . layer . block_root ) activationType = utilities . get_ell_activation_type ( internalNodes ) # Create the ELL fully connected layer ellLayers . append ( ell . neural . FullyConnectedLayer ( layerParameters , weightsTensor ) ) # Create the ELL bias layer isSoftmaxActivation = utilities . is_softmax_activation ( internalNodes ) hasActivation = isSoftmaxActivation or activationType is not None if ( hasActivation ) : layerParameters = middleLayerParameters else : layerParameters = lastLayerParameters ellLayers . append ( ell . neural . BiasLayer ( layerParameters , biasVector ) ) # Create the ELL activation layer if ( hasActivation ) : layerParameters = lastLayerParameters # Special case: if this is softmax activation, create an ELL Softmax layer. # Else, insert an ELL ActivationLayer if ( isSoftmaxActivation ) : ellLayers . append ( ell . neural . SoftmaxLayer ( layerParameters ) ) else : ellLayers . append ( ell . neural . ActivationLayer ( layerParameters , activationType ) )