def create_merged(self, device) -> nn.Linear:
        """Create a merged linear layer with the rotation matrices."""
        weight, bias = self.get_rotated_weights(device)

        linear = nn.Linear(weight.size(1), weight.size(0), bias is not None)
        linear.weight = nn.Parameter(weight.contiguous())
        if bias is not None:
            linear.bias = nn.Parameter(bias.contiguous())

        return linear
Create a merged linear layer with the rotation matrices.
olive/passes/pytorch/rotate.py