code: def test_query_ref_env(data, fn):
      # prepare
      nelem, seed = data
      expect_fn, query_expr = fn
      np.random.seed(seed)
      df = DataFrame()
      df["a"] = aa = np.arange(nelem)
      df["b"] = bb = np.random.random(nelem) * nelem
      c = 2.3
      d = 1.2
      # udt
      expect_mask = expect_fn(aa, bb, c, d)
      print(expect_mask)
      df2 = df.query(query_expr)
      # check
      assert len(df2) == np.count_nonzero(expect_mask)
      np.testing.assert_array_almost_equal(
          df2["a"].to_numpy(), aa[expect_mask]
      )
      np.testing.assert_array_almost_equal(
          df2["b"].to_numpy(), bb[expect_mask]
      )
  
file_path: cudf/python/cudf/cudf/tests/test_query.py
imports: import datetime
  import inspect
  from itertools import product
  import numpy
  import pandas
  import pytest
  import cudf
  from cudf import DataFrame
  from cudf.testing._utils import assert_eq
  from cudf.utils import queryutils
label_desc: Use image node_id 3 for calling a global function with example usage: test_query_ref_env(data, fn) without return types