(self, preset)
Use the given preset during prediction.

        This method changes values of :obj:`self.nms_thresh`,
        :obj:`self.score_thresh`, :obj:`self.mask_merge_thresh`,
        :obj:`self.binary_thresh`, :obj:`self.binary_thresh` and
        :obj:`self.min_drop_size`. These values are a threshold value
        used for non maximum suppression, a threshold value
        to discard low confidence proposals in :meth:`predict`,
        a threshold value to merge mask in :meth:`predict`,
        a threshold value to binalize segmentation scores in :meth:`predict`,
        a limit number of predicted masks in one image and
        a threshold value to discard small bounding boxes respectively.

        If the attributes need to be changed to something
        other than the values provided in the presets, please modify
        them by directly accessing the public attributes.

        Args:
            preset ({'visualize', 'evaluate'): A string to determine the
                preset to use.
Use the given preset during prediction.
Use the given preset during prediction .
def use_preset(self, preset):
        """Use the given preset during prediction.

        This method changes values of :obj:`self.nms_thresh`,
        :obj:`self.score_thresh`, :obj:`self.mask_merge_thresh`,
        :obj:`self.binary_thresh`, :obj:`self.binary_thresh` and
        :obj:`self.min_drop_size`. These values are a threshold value
        used for non maximum suppression, a threshold value
        to discard low confidence proposals in :meth:`predict`,
        a threshold value to merge mask in :meth:`predict`,
        a threshold value to binalize segmentation scores in :meth:`predict`,
        a limit number of predicted masks in one image and
        a threshold value to discard small bounding boxes respectively.

        If the attributes need to be changed to something
        other than the values provided in the presets, please modify
        them by directly accessing the public attributes.

        Args:
            preset ({'visualize', 'evaluate'): A string to determine the
                preset to use.

        """
        if preset == 'visualize':
            self.nms_thresh = 0.3
            self.score_thresh = 0.7
            self.mask_merge_thresh = 0.5
            self.binary_thresh = 0.4
            self.limit = 100
            self.min_drop_size = 16
        elif preset == 'evaluate':
            self.nms_thresh = 0.3
            self.score_thresh = 1e-3
            self.mask_merge_thresh = 0.5
            self.binary_thresh = 0.4
            self.limit = 100
            self.min_drop_size = 16
        elif preset == 'coco_evaluate':
            self.nms_thresh = 0.3
            self.score_thresh = 1e-3
            self.mask_merge_thresh = 0.5
            self.binary_thresh = 0.4
            self.limit = 100
            self.min_drop_size = 2
        else:
            raise ValueError('preset must be visualize or evaluate')
def use_preset ( self , preset ) : if preset == 'visualize' : self . nms_thresh = 0.3 self . score_thresh = 0.7 self . mask_merge_thresh = 0.5 self . binary_thresh = 0.4 self . limit = 100 self . min_drop_size = 16 elif preset == 'evaluate' : self . nms_thresh = 0.3 self . score_thresh = 1e-3 self . mask_merge_thresh = 0.5 self . binary_thresh = 0.4 self . limit = 100 self . min_drop_size = 16 elif preset == 'coco_evaluate' : self . nms_thresh = 0.3 self . score_thresh = 1e-3 self . mask_merge_thresh = 0.5 self . binary_thresh = 0.4 self . limit = 100 self . min_drop_size = 2 else : raise ValueError ( 'preset must be visualize or evaluate' )