def fetch_func_params(
    model: _torch.nn.Module, weight_node: _torch.fx.Node, bias_node: _torch.fx.Node
) -> _Tuple[_Any]:
    """
    Given a model, weight node and bias node, this function fetches the attributes
    corresponding to these nodes and returns them as a 2-tuple (weight, bias)
    """

    weight = None
    if weight_node is not None:
        assert weight_node.op == "get_attr", "unsupported op for weight node"
        weight = fetch_attr(model, weight_node.target)
    bias = None
    if bias_node is not None:
        assert bias_node.op == "get_attr", "unsupported op for bias node"
        bias = fetch_attr(model, bias_node.target)
    return (weight, bias)

    Given a model, weight node and bias node, this function fetches the attributes
    corresponding to these nodes and returns them as a 2-tuple (weight, bias)
    
coremltools/optimize/torch/_utils/transforms.py