def get_groups_from_inventory(inventory):
    """
    Return groups from Ansible Inventory
    :param inventory: Inventory
    :return: Groups
    """
    groups = inventory.groups
    del groups['all']
    return groups