How to pass a reference to a function in yaml config file

If I want to use CLI to initialize datamodule object in lightning I should use:

python train.py --config data.yaml

data:
  class_path: foo.datasets.my_data
  init_args:
    data_dir: data

But what if one the init_arguments is a function? How can I pass a reference to it like this? where foo.datasets.filter1 is a function.

data:
  class_path: foo.datasets.my_data
  init_args:
    data_dir: data
    filter: foo.datasets.filter1