code: def test_summarize_dtypes(X, w):
      X = numpy.array(X)
      X = X.astype(numpy.float32)
  
      p = numpy.array([3.0, 1.1, 2.8], dtype=numpy.float32)
      d = Poisson(p)
      assert d._xw_sum.dtype == torch.float32
      d.summarize(X)
      assert d._xw_sum.dtype == torch.float32
  
      X = X.astype(numpy.float64)
      p = numpy.array([3.0, 1.1, 2.8], dtype=numpy.float32)
      d = Poisson(p)
      assert d._xw_sum.dtype == torch.float32
      d.summarize(X)
      assert d._xw_sum.dtype == torch.float32
  
      X = X.astype(numpy.int32)
      p = numpy.array([3.0, 1.1, 2.8], dtype=numpy.float32)
      d = Poisson(p)
      assert d._xw_sum.dtype == torch.float32
      d.summarize(X)
      assert d._xw_sum.dtype == torch.float32
  
      X = X.astype(numpy.int64)
      p = numpy.array([3.0, 1.1, 2.8], dtype=numpy.float32)
      d = Poisson(p)
      assert d._xw_sum.dtype == torch.float32
      d.summarize(X)
      assert d._xw_sum.dtype == torch.float32
  
imports: import os
  import numpy
  import torch
  import pytest
  from pomegranate.distributions import Poisson
  from ._utils import _test_initialization_raises_one_parameter
  from ._utils import _test_initialization
  from ._utils import _test_predictions
  from ._utils import _test_efd_from_summaries
  from ._utils import _test_raises
  from nose.tools import assert_raises
  from numpy.testing import assert_array_almost_equal
label_desc: Use image node_id 24 for calling a global function with example usage: test_summarize_dtypes(X, w) without return types