def _get_non_neural_features(question_tok_wid, question_lens, context_tok_wid,
                             context_lens):
  """Gets the three non-neural features and the context mask.

  Args:
    question_tok_wid: <int32> [batch_size, question_len]
    question_lens: <int32> [batch_size]
    context_tok_wid: <int32> [batch_size, num_context, context_len]
    context_lens: <int32> [batch_size, num_context]

  Returns:
    question_tok_wid: [batch_size, num_contexts, 1]
    context_tok_wid: [batch_size, num_contexts, 1]
    pos_embs: [batch_size, num_contexts, pos_emb_dim]
  """
  # <int32> [batch_size, num_contexts]
  weighted_num_overlap = _compute_word_overlap(
      context_ids=context_tok_wid,
      context_len=context_lens,
      question_ids=question_tok_wid,
      question_len=question_lens,
      reduce_type=FLAGS.overlap_reduce_type,
      vocab_df=None,
      weighted=True)

  # <int32> [batch_size, num_contexts]
  unweighted_num_overlap = _compute_word_overlap(
      context_ids=context_tok_wid,
      context_len=context_lens,
      question_ids=question_tok_wid,
      question_len=question_lens,
      reduce_type=FLAGS.overlap_reduce_type,
      vocab_df=None,
      weighted=False)

  # <int32> [batch_size, num_contexts, pos_emb_dim]
  pos_embs = _get_position_scores(
      batch_size=tf.shape(context_tok_wid)[0],
      num_contexts=tf.shape(context_tok_wid)[1],
      max_pos_embs=FLAGS.max_pos_embs,
      pos_emb_dim=FLAGS.pos_emb_dim)

  weighted_num_overlap = tf.expand_dims(weighted_num_overlap, -1)
  unweighted_num_overlap = tf.expand_dims(unweighted_num_overlap, -1)

  return weighted_num_overlap, unweighted_num_overlap, pos_embs
Gets the three non-neural features and the context mask.

  Args:
    question_tok_wid: <int32> [batch_size, question_len]
    question_lens: <int32> [batch_size]
    context_tok_wid: <int32> [batch_size, num_context, context_len]
    context_lens: <int32> [batch_size, num_context]

  Returns:
    question_tok_wid: [batch_size, num_contexts, 1]
    context_tok_wid: [batch_size, num_contexts, 1]
    pos_embs: [batch_size, num_contexts, pos_emb_dim]
  
language/question_answering/decatt_docreader/models/nq_long_decatt_model.py