@staticmethod
def CheckDict(arg):
    """Check that the argument is a python dictionary."""
    result = arg
    if arg is None:
        result = dict()
    elif not isinstance(arg, dict):
        raise TypeError('Argument is not a dict')
    return result
