You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: createMaskRCNN.m
    path of file: ./repos/mask-rcnn/src
    
    the code of the file until where you have to start completion: function dlnet = createMaskRCNN(numClasses, params, featureExtractor) 
% Create Mask RCNN network


validatestring(featureExtractor, {'resnet101', 'resnet50'});
% Create FasterRCNN network and modify it to a MaskRCNN
lgraph = fasterRCNNLayers(params.ImageSize, numClasses, params.AnchorBoxes,  featureExtractor);

switch(featureExtractor)

    
function dlnet = createMaskRCNN(numClasses, params, featureExtractor) 
% Create Mask RCNN network


validatestring(featureExtractor, {'resnet101', 'resnet50'});
% Create FasterRCNN network and modify it to a MaskRCNN
lgraph = fasterRCNNLayers(params.ImageSize, numClasses, params.AnchorBoxes,  featureExtractor);

switch(featureExtractor)
    case 'resnet50'
        detectorFeatureLayer = 'activation_49_relu';
        inputLayerName = 'input_1';
    case 'resnet101'
        detectorFeatureLayer = 'res5c_relu';
        inputLayerName = 'data';
    otherwise
        error('Unsupported feature extraction network');
end