class_docstr: This layer performs a special convolution used in BERT architecture
  
  This operation extracts the convolution regions as if 1-dimensional kernel of size (kernel size)
  would move along (sequence length) padded by ((kernel size) - 1 / 2) zeros from both sides.
  Then it applies different kernel values for every position along (sequence length), (batch size) and (num heads).
  The only dimension shared betweed different kernels is (head size).
  The kernel values are provided by an additional input.
  
  :param input_layer: The input layer and the number of its output. If no number
      is specified, the first output will be connected.
  :type input_layer: object, tuple(object, int) of list of them
  :param name: The layer name.
  :type name: str, default=None
  
  .. rublic:: Layer inputs:
  
  (1) convolution data
      - **BatchLength** is equal to (sequence length)
      - **BatchWidth** is equal to (batch size)
      - **Channels** is equal to (attention heads) * (head size)
      - others are equal to 1
  
  (2) convolution kernels
      - **BatchLength** is equal to (sequence length)
      - **BatchWidth** is equal to (batch size) * (attention heads)
      - **Height** is equal to (kernel size)
      - others are equal to 1
  
  .. rubric:: Layer outputs:
  
  (2) convolution result
      - **BatchLength** is equal to (sequence length)
      - **BatchWidth** is equal to (batch size) * (attention heads)
      - **Height** is equal to (head size)
      - others are equal to 1
class_docstr_tok: ["This","layer","performs","a","special","convolution","used","in","BERT","architecture","This","operation","extracts","the","convolution","regions","as","if","1-dimensional","kernel","of","size","(","kernel","size",")","would","move","along","(","sequence","length",")","padded","by","(","(","kernel","size",")","-","1","\/","2",")","zeros","from","both","sides",".","Then","it","applies","different","kernel","values","for","every","position","along","(","sequence","length",")",",","(","batch","size",")","and","(","num","heads",")",".","The","only","dimension","shared","betweed","different","kernels","is","(","head","size",")",".","The","kernel","values","are","provided","by","an","additional","input",".",":","param","input_layer",":","The","input","layer","and","the","number","of","its","output",".","If","no","number","is","specified",",","the","first","output","will","be","connected",".",":","type","input_layer",":","object",",","tuple","(","object",",","int",")","of","list","of","them",":","param","name",":","The","layer","name",".",":","type","name",":","str",",","default=None","..","rublic",":",":","Layer","inputs",":","(","1",")","convolution","data","-","*","*","BatchLength","*","*","is","equal","to","(","sequence","length",")","-","*","*","BatchWidth","*","*","is","equal","to","(","batch","size",")","-","*","*","Channels","*","*","is","equal","to","(","attention","heads",")","*","(","head","size",")","-","others","are","equal","to","1","(","2",")","convolution","kernels","-","*","*","BatchLength","*","*","is","equal","to","(","sequence","length",")","-","*","*","BatchWidth","*","*","is","equal","to","(","batch","size",")","*","(","attention","heads",")","-","*","*","Height","*","*","is","equal","to","(","kernel","size",")","-","others","are","equal","to","1","..","rubric",":",":","Layer","outputs",":","(","2",")","convolution","result","-","*","*","BatchLength","*","*","is","equal","to","(","sequence","length",")","-","*","*","BatchWidth","*","*","is","equal","to","(","batch","size",")","*","(","attention","heads",")","-","*","*","Height","*","*","is","equal","to","(","head","size",")","-","others","are","equal","to","1"]
code: def __init__(self, input_layer, name=None):
      if type(input_layer) is PythonWrapper.BertConv:
          super().__init__(input_layer)
          return
  
      layers, outputs = check_input_layers(input_layer, 2)
  
      internal = PythonWrapper.BertConv(str(name), layers, outputs)
      super().__init__(internal)
  
imports: import neoml.PythonWrapper
  from .Dnn import Layer
  from neoml.Utils import check_input_layers
label_desc: Use image node_id 1 to create a new BertConv object from inherited base classes: Layer with example: obj = BertConv(input_layer, name)