def assert_callable(f):
    """
    Raise a `TypeError` if an object is not callable.

    Args:
        f: The object to check.
    """
    if not callable(f):
        raise TypeError(f"'{type(f)}' object is not callable")
