code: def test_get_gpu_tag_from_model_func():
      # test getting the gpu tags from the model that we use in explainers
      model = reg()
  
      order = get_tag_from_model_func(
          func=model.predict, tag="preferred_input_order", default="C"
      )
  
      assert order == "F"
  
      out_types = get_tag_from_model_func(
          func=model.predict, tag="X_types_gpu", default=False
      )
  
      assert isinstance(out_types, list)
      assert "2darray" in out_types
  
      # checking arbitrary function
      order = get_tag_from_model_func(
          func=dummy_func, tag="preferred_input_order", default="C"
      )
  
      assert order == "C"
  
      out_types = get_tag_from_model_func(
          func=dummy_func, tag="X_types_gpu", default=False
      )
  
      assert out_types is False
  
      model2 = skreg()
  
      out_types = get_tag_from_model_func(
          func=model2.predict, tag="X_types_gpu", default=False
      )
  
      assert out_types is False
  
imports: from pylibraft.common.handle import Handle
  from sklearn.linear_model import LinearRegression
  from cuml.datasets import make_regression
  from cuml.testing.utils import ClassEnumerator
  from cuml.explainer.common import model_func_call
  from cuml.explainer.common import link_dict
  from cuml.explainer.common import get_tag_from_model_func
  from cuml.explainer.common import get_link_fn_from_str_or_fn
  from cuml.explainer.common import get_handle_from_cuml_model_func
  from cuml.explainer.common import get_dtype_from_model_func
  from cuml.explainer.common import get_cai_ptr
  from cuml import PCA
  from cuml import LinearRegression
  import pytest
  from cuml.internals.safe_imports import cpu_only_import
  import cuml
  from cuml.internals.safe_imports import gpu_only_import
label_desc: Use image node_id 2 for calling a global function with example usage: test_get_gpu_tag_from_model_func() without return types