Skip to content

create_dl_layer_identityCreateDlLayerIdentityCreateDlLayerIdentitycreate_dl_layer_identityT_create_dl_layer_identity🔗

Short description🔗

create_dl_layer_identityCreateDlLayerIdentityCreateDlLayerIdentitycreate_dl_layer_identityT_create_dl_layer_identity — Create an identity layer.

Signature🔗

create_dl_layer_identity( dl_layer DLLayerInput, string LayerName, attribute.name GenParamName, attribute.value GenParamValue, out dl_layer DLLayerIdentity )void CreateDlLayerIdentity( const HTuple& DLLayerInput, const HTuple& LayerName, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* DLLayerIdentity )static void HOperatorSet.CreateDlLayerIdentity( HTuple DLLayerInput, HTuple layerName, HTuple genParamName, HTuple genParamValue, out HTuple DLLayerIdentity )def create_dl_layer_identity( dllayer_input: HHandle, layer_name: str, gen_param_name: MaybeSequence[str], gen_param_value: MaybeSequence[Union[int, float, str]] ) -> HHandle

Herror T_create_dl_layer_identity( const Htuple DLLayerInput, const Htuple LayerName, const Htuple GenParamName, const Htuple GenParamValue, Htuple* DLLayerIdentity )

HDlLayer HDlLayer::CreateDlLayerIdentity( const HString& LayerName, const HTuple& GenParamName, const HTuple& GenParamValue ) const

HDlLayer HDlLayer::CreateDlLayerIdentity( const HString& LayerName, const HString& GenParamName, const HString& GenParamValue ) const

HDlLayer HDlLayer::CreateDlLayerIdentity( const char* LayerName, const char* GenParamName, const char* GenParamValue ) const

HDlLayer HDlLayer::CreateDlLayerIdentity( const wchar_t* LayerName, const wchar_t* GenParamName, const wchar_t* GenParamValue ) const (Windows only)

HDlLayer HDlLayer.CreateDlLayerIdentity( string layerName, HTuple genParamName, HTuple genParamValue )

HDlLayer HDlLayer.CreateDlLayerIdentity( string layerName, string genParamName, string genParamValue )

Description🔗

The operator create_dl_layer_identityCreateDlLayerIdentity creates an identity layer whose handle is returned in DLLayerIdentityDLLayerIdentitydllayer_identity.

The parameter DLLayerInputDLLayerInputdllayer_input determines the feeding input layer and expects the layer handle as value.

The parameter LayerNamelayerNamelayer_name sets an individual layer name. Note that if creating a model using create_dl_modelCreateDlModel each layer of the created network must have a unique name.

The following generic parameters GenParamNamegenParamNamegen_param_name and the corresponding values GenParamValuegenParamValuegen_param_value are supported:

  • 'is_inference_output'"is_inference_output": Determines whether apply_dl_modelApplyDlModel will include the output of this layer in the dictionary DLResultBatchDLResultBatchdlresult_batch even without specifying this layer in Outputsoutputsoutputs ('true'"true") or not ('false'"false").

    Default: 'false'"false"

Certain parameters of layers created using this operator create_dl_layer_identityCreateDlLayerIdentity can be set and retrieved using further operators. The following tables give an overview, which parameters can be set using set_dl_model_layer_paramSetDlModelLayerParam and which ones can be retrieved using get_dl_model_layer_paramGetDlModelLayerParam or get_dl_layer_paramGetDlLayerParam. Note, the operators set_dl_model_layer_paramSetDlModelLayerParam and get_dl_model_layer_paramGetDlModelLayerParam require a model created by create_dl_modelCreateDlModel.

Layer Parameters set get
'input_layer'"input_layer" (DLLayerInputDLLayerInputdllayer_input) x
'name'"name" (LayerNamelayerNamelayer_name) x x
'output_layer'"output_layer" (DLLayerIdentityDLLayerIdentitydllayer_identity) x
'shape'"shape" x
'type'"type" x
Generic Layer Parameters set get
'is_inference_output'"is_inference_output" x x
'num_trainable_params'"num_trainable_params" x

Execution information🔗

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

Parameters🔗

DLLayerInputDLLayerInputdllayer_input (input_control) dl_layer → (handle)HTuple (HHandle)HDlLayer, HTuple (IntPtr)HHandleHtuple (handle)

Feeding layer.

LayerNamelayerNamelayer_name (input_control) string → (string)HTuple (HString)HTuple (string)strHtuple (char*)

Name of the output layer.

GenParamNamegenParamNamegen_param_name (input_control) attribute.name(-array) → (string)HTuple (HString)HTuple (string)MaybeSequence[str]Htuple (char*)

Generic input parameter names.

Default: [][]
List of values: 'is_inference_output'"is_inference_output"

GenParamValuegenParamValuegen_param_value (input_control) attribute.value(-array) → (string / integer / real)HTuple (HString / Hlong / double)HTuple (string / int / long / double)MaybeSequence[Union[int, float, str]]Htuple (char* / Hlong / double)

Generic input parameter values.

Default: [][]
Suggested values: 'true', 'false'"true", "false"

DLLayerIdentityDLLayerIdentitydllayer_identity (output_control) dl_layer → (handle)HTuple (HHandle)HDlLayer, HTuple (IntPtr)HHandleHtuple (handle)

Identity layer.

Example🔗

(HDevelop)

* Create a model that concatinates the output of a convolution layer.
create_dl_layer_input ('input', [10,10,3], [], [], DLLayerInput)
create_dl_layer_convolution (DLLayerInput, 'conv', 3, 1, 1, 8, 1, 'none', \
                            'none', [], [], DLLayerConvolution)
* Using the same layer multiple times as input does not work, so make a copy.
create_dl_layer_identity (DLLayerConvolution, 'conv_copy', [], [], \
                          DLLayerIdentity)
create_dl_layer_concat ([DLLayerConvolution, DLLayerIdentity], 'concat', \
                        'depth', [], [], DLLayerConcat)
create_dl_model (DLLayerConcat, DLModelHandle)

Combinations with other operators🔗

Combinations

Possible successors

create_dl_layer_elementwiseCreateDlLayerElementwise, create_dl_layer_concatCreateDlLayerConcat

Module🔗

Deep Learning Professional