class_docstr: Match-SRNN Model.
  
  Examples:
      >>> model = MatchSRNN()
      >>> model.params['channels'] = 4
      >>> model.params['units'] = 10
      >>> model.params['dropout_rate'] = 0.0
      >>> model.params['direction'] = 'lt'
      >>> model.guess_and_fill_missing_params(verbose=0)
      >>> model.build()
class_docstr_tok: ["Match-SRNN","Model",".","Examples",":",">",">",">","model","=","MatchSRNN","(",")",">",">",">","model.params","[","'channels","'","]","=","4",">",">",">","model.params","[","'units","'","]","=","10",">",">",">","model.params","[","'dropout_rate","'","]","=","0.0",">",">",">","model.params","[","'direction","'","]","=","'lt'",">",">",">","model.guess_and_fill_missing_params","(","verbose=0",")",">",">",">","model.build","(",")"]
docstr: Build model structure.
  
  Match-SRNN: Modeling the Recursive Matching Structure
      with Spatial RNN
docstr_tok: ["Build","model","structure",".","Match-SRNN",":","Modeling","the","Recursive","Matching","Structure","with","Spatial","RNN"]
code: def build(self):
      """
      Build model structure.
  
      Match-SRNN: Modeling the Recursive Matching Structure
          with Spatial RNN
      """
  
      # Scalar dimensions referenced here:
      #   B = batch size (number of sequences)
      #   D = embedding size
      #   L = `input_left` sequence length
      #   R = `input_right` sequence length
      #   C = number of channels
  
      # Left input and right input.
      # query = [B, L]
      # doc = [B, R]
      query, doc = self._make_inputs()
  
      # Process left and right input.
      # embed_query = [B, L, D]
      # embed_doc = [B, R, D]
      embedding = self._make_embedding_layer()
      embed_query = embedding(query)
      embed_doc = embedding(doc)
  
      # Get matching tensor
      # matching_tensor = [B, C, L, R]
      matching_tensor_layer = MatchingTensorLayer(
          channels=self._params["channels"]
      )
      matching_tensor = matching_tensor_layer([embed_query, embed_doc])
  
      # Apply spatial GRU to the word level interaction tensor
      # h_ij = [B, U]
      spatial_gru = SpatialGRU(
          units=self._params["units"],
          direction=self._params["direction"],
      )
      h_ij = spatial_gru(matching_tensor)
  
      # Apply Dropout
      x = keras.layers.Dropout(rate=self._params["dropout_rate"])(h_ij)
  
      # Make output layer
      x_out = self._make_output_layer()(x)
  
      self._backend = keras.Model(inputs=[query, doc], outputs=x_out)
  
file_path: MatchZoo/matchzoo/contrib/models/match_srnn.py
imports: import keras
  from matchzoo.contrib.layers import MatchingTensorLayer
  from matchzoo.contrib.layers import SpatialGRU
  from matchzoo.engine import hyper_spaces
  from matchzoo.engine.base_model import BaseModel
  from matchzoo.engine.param import Param
  from matchzoo.engine.param_table import ParamTable
label_desc: Use image node_id 2 for calling the MatchSRNN obj's underlying member method code with example usage: obj.build() without return types