code: def test_onehot_get_feature_names(as_array):
      fruits = ["apple", "banana", "strawberry"]
      if as_array:
          fruits = [ord(fruit[0]) for fruit in fruits]
      sizes = [0, 1, 2]
      X = DataFrame({"fruits": fruits, "sizes": sizes})
      if as_array:
          X = _from_df_to_cupy(X)
  
      enc = OneHotEncoder().fit(X)
  
      feature_names_ref = ["x0_" + str(fruit) for fruit in fruits] + [
          "x1_" + str(size) for size in sizes
      ]
      feature_names = enc.get_feature_names()
      assert np.array_equal(feature_names, feature_names_ref)
  
      feature_names_ref = [
          "fruit_" + str(fruit) for fruit in fruits
      ] + ["size_" + str(size) for size in sizes]
      feature_names = enc.get_feature_names(["fruit", "size"])
      assert np.array_equal(feature_names, feature_names_ref)
  
imports: from sklearn.preprocessing import OneHotEncoder
  from cuml.testing.utils import stress_param, from_df_to_numpy, assert_inverse_equal, generate_inputs_from_categories
  from cuml.preprocessing import OneHotEncoder
  from cuml.internals.safe_imports import gpu_only_import_from
  import pytest
  from cuml.internals.safe_imports import cpu_only_import
  import math
  from cuml.internals.safe_imports import gpu_only_import
label_desc: Use image node_id 18 for calling a global function with example usage: test_onehot_get_feature_names(as_array) without return types