from typing import Dict
from typing import AnyStr
from typing import List


def extract_frames_labels(frame: Dict,
                          column_name: AnyStr,
                          labels: List) -> Dict:
    """
    Extract the labels from a frame.

    :frame (Dict) A dictionary containing the frame.
    :column_Name (AnyStr) A string representing the name of the column.
    :labels (List) A list containing the labels names.

    Return a dictionary containing the frame labels.
    """
    frame_labels = {}
    for key, value in frame.items():
        if key not in ['period_start',
                       'period_end',
                       'pod',
                       'namespace',
                       'node',
                       column_name] and key in labels:
            frame_labels[key] = value
    return frame_labels