from typing import Any


def islocal(obj: Any) -> bool:
    """Check if a given obj is on the local machine (in Duet or VM).

    Args:
        obj (Any): Object.

    Returns:
        bool: True (if pointer) or False (if not).
    """
    party_type = obj.client.class_name
    return party_type in {"VirtualMachineClient", "DomainClient"}