this time i am getting " ‘Model’ object is not callable". And yes it is Fasterrcnn pre-trained model which is of torchvision. I looked into the source code of Detecto and what they are doing is loading the pre-trained model, removing last layer of the model and adding a custom layer of output node of length equal to no. of classes we pass in it and all these they are doing it in the Model class they created.
Code

class Model:
def init(self, classes=None, device=None):
    self._device = device if device else config['default_device']

    # Load a model pre-trained on COCO
    self._model = torchvision.models.detection.fasterrcnn_resnet50_fpn(pretrained=True)

    if classes:
        # Get the number of input features for the classifier
        in_features = self._model.roi_heads.box_predictor.cls_score.in_features
        # Replace the pre-trained head with a new one (note: +1 because of the __background__ class)
        self._model.roi_heads.box_predictor = FastRCNNPredictor(in_features, len(classes) + 1)
        self._disable_normalize = False
    else:
        classes = config['default_classes']
        self._disable_normalize = True

    self._model.to(self._device)

    # Mappings to convert from string labels to ints and vice versa
    self._classes = ['__background__'] + classes
    self._int_mapping = {label: index for index, label in enumerate(self._classes)}