code: def poisson_regression_rows(
      test,
      y,
      x,
      covariates,
      pass_through=(),
      *,
      max_iterations: int = 25,
      tolerance: Optional[float] = None,
  ) -> Table:
      r"""For each row, test an input variable for association with a
      count response variable using `Poisson regression <https://en.wikipedia.org/wiki/Poisson_regression>`__.
  
      Notes
      -----
      See :func:`.logistic_regression_rows` for more info on statistical tests
      of general linear models.
  
      Note
      ----
      Use the `pass_through` parameter to include additional row fields from
      matrix table underlying ``x``. For example, to include an "rsid" field, set
      ``pass_through=['rsid']`` or ``pass_through=[mt.rsid]``.
  
      Parameters
      ----------
      y : :class:`.Float64Expression`
          Column-indexed response expression.
          All non-missing values must evaluate to a non-negative integer.
      x : :class:`.Float64Expression`
          Entry-indexed expression for input variable.
      covariates : :obj:`list` of :class:`.Float64Expression`
          Non-empty list of column-indexed covariate expressions.
      pass_through : :obj:`list` of :class:`str` or :class:`.Expression`
          Additional row fields to include in the resulting table.
      tolerance : :obj:`float`, optional
          The iterative fit of this model is considered "converged" if the change in the estimated
          beta is smaller than tolerance. By default the tolerance is 1e-6.
  
      Returns
      -------
      :class:`.Table`
  
      """
      if hl.current_backend().requires_lowering:
          return _lowered_poisson_regression_rows(
              test,
              y,
              x,
              covariates,
              pass_through,
              max_iterations=max_iterations,
              tolerance=tolerance,
          )
  
      if tolerance is None:
          tolerance = 1e-6
      assert tolerance > 0.0
  
      if len(covariates) == 0:
          raise ValueError(
              "Poisson regression requires at least one covariate expression"
          )
  
      mt = matrix_table_source("poisson_regression_rows/x", x)
      raise_unless_entry_indexed("poisson_regression_rows/x", x)
  
      analyze("poisson_regression_rows/y", y, mt._col_indices)
  
      all_exprs = [y]
      for e in covariates:
          all_exprs.append(e)
          analyze(
              "poisson_regression_rows/covariates", e, mt._col_indices
          )
  
      _warn_if_no_intercept("poisson_regression_rows", covariates)
  
      x_field_name = Env.get_uid()
      y_field_name = "__y"
      cov_field_names = list(
          f"__cov{i}" for i in range(len(covariates))
      )
      row_fields = _get_regression_row_fields(
          mt, pass_through, "poisson_regression_rows"
      )
  
      # FIXME: selecting an existing entry field should be emitted as a SelectFields
      mt = mt._select_all(
          col_exprs=dict(
              **{y_field_name: y},
              **dict(zip(cov_field_names, covariates)),
          ),
          row_exprs=row_fields,
          col_key=[],
          entry_exprs={x_field_name: x},
      )
  
      config = {
          "name": "PoissonRegression",
          "test": test,
          "yField": y_field_name,
          "xField": x_field_name,
          "covFields": cov_field_names,
          "passThrough": [x for x in row_fields if x not in mt.row_key],
          "maxIterations": max_iterations,
          "tolerance": tolerance,
      }
  
      return Table(ir.MatrixToTableApply(mt._mir, config)).persist()
  
imports: import builtins
  import itertools
  import math
  from typing import Dict, Callable, Optional, Union, Tuple, List
  import hail
  import hail
  import hail.expr.aggregators
  from hail import ir
  from hail.expr import Expression, ExpressionException, expr_float64, expr_call, expr_any, expr_numeric, expr_locus, analyze, raise_unless_entry_indexed, raise_unless_row_indexed, matrix_table_source, table_source, raise_unless_column_indexed
  from hail.expr.types import tbool, tarray, tfloat64, tint32
  from hail.genetics.reference_genome import reference_genome_type
  from hail.linalg import BlockMatrix
  from hail.matrixtable import MatrixTable
  from hail.methods.misc import require_biallelic, require_row_key_variant
  from hail.stats import LinearMixedModel
  from hail.table import Table
  from hail.typecheck import typecheck, nullable, numeric, oneof, sized_tupleof, sequenceof, enumeration, anytype
  from hail.utils import wrap_to_list, new_temp_file, FatalError
  from hail.utils.java import Env, info, warning
  from .None import pca
  from .None import relatedness
  from ..backend.spark_backend import SparkBackend
label_desc: Use image node_id 15 for calling a global function with example usage: poisson_regression_rows(test, y, x, covariates, pass_through) and returns: Table, _lowered_poisson_regression_rows