from typing import List
from typing import Tuple
import torch


def load_weights(weight_path: str) -> List[Tuple[str, torch.Tensor]]:
    """
    Process the given state dict and return dictionary with matching layers
    Parameters:
        weight_path (str): the path to the weight file
    Returns:
        A list of layer names and weights for the model
    """
    model = torch.load(weight_path)
    model_weight = [(k, v) for (k, v) in model.items() if 'anchor' not in k]
    return model_weight