def get_field(key, obj):
    """
    Get field in dictionary.

    :param key: path to field in dictionary
    :type key: str

    :param obj: dictionary used for search
    :type obj: dict

    :returns: field value
    """
    val = obj
    for subkey in key.split('.'):
        val = val[subkey]
    return val
