code: def _check_pca_int_dtype_upcast_to_double(svd_solver):
      # Ensure that all int types will be upcast to float64
      X_i64 = mt.tensor(
          np.random.RandomState(0).randint(0, 1000, (1000, 4))
      )
      X_i64 = X_i64.astype(np.int64, copy=False)
      X_i32 = X_i64.astype(np.int32, copy=False)
  
      pca_64 = PCA(
          n_components=3, svd_solver=svd_solver, random_state=0
      ).fit(X_i64)
      pca_32 = PCA(
          n_components=3, svd_solver=svd_solver, random_state=0
      ).fit(X_i32)
  
      assert pca_64.components_.dtype == np.float64
      assert pca_32.components_.dtype == np.float64
      assert pca_64.transform(X_i64).dtype == np.float64
      assert pca_32.transform(X_i32).dtype == np.float64
  
      assert_array_almost_equal(
          pca_64.components_.to_numpy(),
          pca_32.components_.to_numpy(),
          decimal=5,
      )
  
imports: from itertools import product
  import numpy
  import pytest
  import scipy
  from sklearn import datasets
  from sklearn.utils._testing import assert_array_almost_equal, assert_almost_equal, assert_raises_regex, assert_raise_message, assert_raises
  from ....None import tensor
  from .._pca import PCA, _assess_dimension, _infer_dimension
label_desc: Use image node_id 29 for calling a global function with example usage: _check_pca_int_dtype_upcast_to_double(svd_solver) without return types