code: def test_kwargs(predict_pandas_mock):
      with create_dict_checkpoint(
          {"factor": 2.0}, checkpoint_cls=FrameworkCheckpoint
      ) as checkpoint:
          predictor = DummyPredictor.from_checkpoint(checkpoint)
  
      input = pd.DataFrame({"x": [1, 2, 3]})
      predictor.predict(input, extra_arg=1)
  
      # Second element in call_args is the kwargs.
      assert "extra_arg" in predict_pandas_mock.call_args[1]
      assert predict_pandas_mock.call_args[1]["extra_arg"] == 1
  
imports: import uuid
  from typing import Dict, Optional, Union
  from unittest import mock
  import numpy
  import pandas
  import pytest
  import ray
  from ray.air.constants import TENSOR_COLUMN_NAME
  from ray.air.util.data_batch_conversion import BatchFormat
  from ray.data import Preprocessor
  from ray.train._internal.framework_checkpoint import FrameworkCheckpoint
  from ray.train.predictor import Predictor, PredictorNotSerializableException
  from ray.train.tests.util import create_dict_checkpoint, load_dict_checkpoint
label_desc: Use image node_id 7 for calling a global function with example usage: test_kwargs(predict_pandas_mock) without return types