MCPcopy Create free account

hub / github.com/Kazuhito00/sahi-yolox-onnx-sample / functions

Functions388 in github.com/Kazuhito00/sahi-yolox-onnx-sample

↓ 43 callersMethodtolist
(self)
sahi/postprocess/utils.py:59
↓ 42 callersMethoddeepcopy
Returns: deepcopy of current ObjectAnnotation instance
sahi/annotation.py:686
↓ 20 callersFunction_cocoeval_summarize
( cocoeval, ap=1, iouThr=None, catIdx=None, areaRng="all", maxDets=100, catName="", nameStrLen=None )
sahi/scripts/coco_evaluation.py:13
↓ 19 callersMethodto_xyxy
[xmin, ymin, xmax, ymax]
sahi/utils/shapely.py:215
↓ 14 callersFunctionget_package_info
Returns the package version as a string and the package name as a string.
sahi/utils/import_utils.py:15
↓ 10 callersFunctionload_json
Loads json formatted data (given as "data") from load_path Encoding type can be specified with 'encoding' argument Example inputs:
sahi/utils/file.py:58
↓ 9 callersFunctioncheck_requirements
Raise error if module is not installed.
sahi/utils/import_utils.py:57
↓ 8 callersFunctioncalculate_area
Args: box (List[int]): [x1, y1, x2, y2]
sahi/postprocess/utils.py:107
↓ 8 callersMethodto_xyxy
Returns: [xmin, ymin, xmax, ymax]
sahi/annotation.py:84
↓ 7 callersMethodadd_image
Adds image to this Coco instance Args: image: CocoImage
sahi/utils/coco.py:869
↓ 7 callersFunctionis_available
(module_name: str)
sahi/utils/import_utils.py:53
↓ 6 callersFunctionsave_json
Saves json formatted data (given as "data") as save_path Example inputs: data: {"image_id": 5} save_path: "dirname/coco.json"
sahi/utils/file.py:30
↓ 5 callersMethodadd_categories_from_coco_category_list
Creates CocoCategory object using coco category list. Args: coco_category_list: List[Dict] [
sahi/utils/coco.py:835
↓ 5 callersMethodfrom_coco_dict_or_path
Creates coco object from COCO formatted dict or COCO dataset file path. Args: coco_dict_or_path: dict/str or List[dict/s
sahi/utils/coco.py:988
↓ 5 callersMethodfrom_coco_segmentation
Init Mask from coco segmentation representation. Args: segmentation : List[List] [ [
sahi/annotation.py:165
↓ 5 callersMethodfrom_pretrained
Loads a DetectionModel from given path. Args: model_type: str Name of the detection framework (example:
sahi/auto_model.py:16
↓ 5 callersFunctionget_prediction
Function for performing prediction for given image using given detection_model. Arguments: image: str or np.ndarray Loca
sahi/predict.py:55
↓ 5 callersMethodget_shifted_box
Returns: shifted BoundingBox
sahi/annotation.py:96
↓ 5 callersMethodget_shifted_mask
(self)
sahi/annotation.py:274
↓ 5 callersFunctionread_image_as_pil
Loads an image as PIL.Image.Image. Args: image : Can be image path or url (str), numpy image (np.ndarray) or PIL.Image
sahi/utils/cv.py:140
↓ 5 callersMethodto_coco_segmentation
Returns boolean mask as coco segmentation: [ [x1, y1, x2, y2, x3, y3, ...], [x1, y1, x2, y2, x3, y3, ...],
sahi/annotation.py:306
↓ 5 callersMethodto_xywh
Returns: [xmin, ymin, width, height]
sahi/annotation.py:72
↓ 4 callersMethodadd_annotation
Adds annotation to this CocoImage instance annotation : CocoAnnotation
sahi/utils/coco.py:588
↓ 4 callersFunctioncalculate_intersection_area
Args: box1 (np.ndarray): np.array([x1, y1, x2, y2]) box2 (np.ndarray): np.array([x1, y1, x2, y2])
sahi/postprocess/utils.py:115
↓ 4 callersFunctionexport_yolov5_images_and_txts_from_coco_object
Creates image symlinks and annotation txts in yolo format from coco dataset. Args: output_dir: str Export directory.
sahi/utils/coco.py:1506
↓ 4 callersMethodextend
(self, object_prediction_list)
sahi/postprocess/utils.py:50
↓ 4 callersFunctionfix_full_shape_list
(full_shape_list)
sahi/utils/compatibility.py:8
↓ 4 callersFunctionfix_shift_amount_list
(shift_amount_list)
sahi/utils/compatibility.py:1
↓ 4 callersMethodfrom_coco_bbox
Creates ObjectAnnotation from coco bbox [minx, miny, width, height] Args: bbox: List [minx, miny, width,
sahi/annotation.py:401
↓ 4 callersFunctionget_resolution_selector
Args: res: resolution of image such as low, medium height: width: Returns: trigger slicing params function
sahi/slicing.py:602
↓ 4 callersFunctionupdate_categories
Rearranges category mapping of given COCO dictionary based on given category_mapping. Can also be used to filter some of the categories.
sahi/utils/coco.py:1609
↓ 4 callersFunctionvisualize_object_predictions
Visualizes prediction category names, bounding boxes over the source image and exports it to output folder. Arguments: object_pre
sahi/utils/cv.py:397
↓ 3 callersMethod__init__
Creates Coco object. Args: name: str Name of the Coco dataset, it determines exported json name.
sahi/utils/coco.py:797
↓ 3 callersFunctioncalc_ratio_and_slice
According to image resolution calculation overlap params Args: orientation: image capture angle slide: sliding window
sahi/slicing.py:504
↓ 3 callersFunctioncreate_fiftyone_dataset_from_coco_file
(coco_image_dir: str, coco_json_path: str)
sahi/utils/fiftyone.py:67
↓ 3 callersFunctiondownload_from_url
(from_url: str, to_path: str)
sahi/utils/file.py:228
↓ 3 callersFunctionget_bbox_from_bool_mask
Generate voc bbox ([xmin, ymin, xmax, ymax]) from given bool_mask (2D np.ndarray)
sahi/utils/cv.py:530
↓ 3 callersFunctionget_bbox_from_shapely
Accepts shapely box/poly object and returns its bounding box in coco and voc formats
sahi/utils/shapely.py:36
↓ 3 callersFunctionget_bool_mask_from_coco_segmentation
Convert coco segmentation to 2D boolean mask of given height and width
sahi/utils/cv.py:518
↓ 3 callersFunctionget_sliced_prediction
Function for slice image + get predicion for each slice + combine predictions in full image. Args: image: str or np.ndarray
sahi/predict.py:123
↓ 3 callersMethodload_model
This function should be implemented in a way that detection model should be initialized and set to self.model. (self.model_pa
sahi/models/base.py:75
↓ 3 callersFunctionnms
Apply non-maximum suppression to avoid detecting too many overlapping bounding boxes for a given object. Args: predictions: (tens
sahi/postprocess/combine.py:43
↓ 3 callersMethodto_xywh
[xmin, ymin, width, height]
sahi/utils/shapely.py:193
↓ 3 callersMethodtotensor
(self)
sahi/postprocess/utils.py:53
↓ 2 callersFunction_autolabel
Attach a text label above each bar in *rects*, displaying its height.
sahi/scripts/coco_error_analysis.py:77
↓ 2 callersMethod_has_match
(self, pred1: ObjectPrediction, pred2: ObjectPrediction)
sahi/postprocess/legacy/combine.py:32
↓ 2 callersFunction_makebarplot
(rs, ps, outDir, class_name, iou_type)
sahi/scripts/coco_error_analysis.py:96
↓ 2 callersFunction_makeplot
(rs, ps, outDir, class_name, iou_type)
sahi/scripts/coco_error_analysis.py:23
↓ 2 callersMethod_nms
(self, boxes, scores, nms_thr)
yolox/yolox_onnx.py:158
↓ 2 callersMethodadd_category
Adds category to this Coco instance Args: category: CocoCategory
sahi/utils/coco.py:856
↓ 2 callersFunctionannotation_inside_slice
Check whether annotation coordinates lie inside slice coordinates. Args: annotation (dict): Single annotation entry in COCO format.
sahi/slicing.py:95
↓ 2 callersFunctionapply_color_mask
Applies color mask to given input image.
sahi/utils/cv.py:203
↓ 2 callersFunctioncalculate_box_union
Args: box1 (List[int]): [x1, y1, x2, y2] box2 (List[int]): [x1, y1, x2, y2]
sahi/postprocess/utils.py:94
↓ 2 callersFunctioncreate_coco_dict
Creates COCO dict with fields "images", "annotations", "categories". Arguments --------- images : List of CocoImage containing a
sahi/utils/coco.py:1855
↓ 2 callersMethodfrom_coco_annotation_dict
Creates CocoAnnotation object from category name and COCO formatted annotation dict (with fields "bbox", "segmentation", "category_id
sahi/utils/coco.py:118
↓ 2 callersMethodfrom_coco_bbox
Creates CocoAnnotation object using coco bbox Args: bbox: List [xmin, ymin, width, height] c
sahi/utils/coco.py:96
↓ 2 callersMethodfrom_coco_category
Creates CocoCategory object using coco category. Args: category: Dict {"supercategory": "person", "id":
sahi/utils/coco.py:39
↓ 2 callersMethodfrom_coco_image_dict
Creates CocoImage object from COCO formatted image dict (with fields "id", "file_name", "height" and "weight"). Args: im
sahi/utils/coco.py:552
↓ 2 callersFunctionget_shapely_multipolygon
Accepts coco style polygon coords and converts it to shapely multipolygon object
sahi/utils/shapely.py:22
↓ 2 callersMethodget_sliced_coco_annotation
(self, slice_bbox: List[int])
sahi/utils/coco.py:222
↓ 2 callersFunctiongreedy_nmm
Apply greedy version of non-maximum merging to avoid detecting too many overlapping bounding boxes for a given object. Args: obje
sahi/postprocess/combine.py:181
↓ 2 callersFunctionhas_match
( pred1: ObjectPrediction, pred2: ObjectPrediction, match_type: str = "IOU", match_threshold: float = 0.5
sahi/postprocess/utils.py:148
↓ 2 callersFunctionincrement_path
(path, exist_ok=True, sep="")
sahi/utils/file.py:215
↓ 2 callersFunctionis_torch_cuda_available
()
sahi/utils/torch.py:45
↓ 2 callersFunctionmerge
Combines 2 coco formatted annotations dicts, and returns the combined coco dict. Arguments: --------- coco_dict1 : dict
sahi/utils/coco.py:1692
↓ 2 callersFunctionmerge_object_prediction_pair
( pred1: ObjectPrediction, pred2: ObjectPrediction, )
sahi/postprocess/utils.py:193
↓ 2 callersFunctionnmm
Apply non-maximum merging to avoid detecting too many overlapping bounding boxes for a given object. Args: object_predictions_as_
sahi/postprocess/combine.py:335
↓ 2 callersFunctionslice_image
Slice a large image into smaller windows. If output_file_name is given export sliced images. Args: image (str or PIL.Image): File pat
sahi/slicing.py:262
↓ 2 callersMethodsplit_coco_as_train_val
Split images into train-val and returns them as sahi.utils.coco.Coco objects. Args: train_split_rate: float
sahi/utils/coco.py:1183
↓ 2 callersMethodto_coco_prediction
Returns sahi.utils.coco.CocoPrediction representation of ObjectAnnotation.
sahi/prediction.py:111
↓ 2 callersMethodto_coco_segmentation
[ [x1, y1, x2, y2, x3, y3, ...], [x1, y1, x2, y2, x3, y3, ...], ... ]
sahi/utils/shapely.py:132
↓ 1 callersMethod__init__
Arguments: score: prediction score between 0 and 1
sahi/prediction.py:17
↓ 1 callersFunction_analyse_results
( res_file, ann_file, res_types, out_dir=None, extraplots=None, areas=None, max_de
sahi/scripts/coco_error_analysis.py:286
↓ 1 callersMethod_apply_category_remapping
Applies category remapping based on mapping given in self.category_remapping
sahi/models/base.py:140
↓ 1 callersMethod_create_object_prediction_list_from_original_predictions
This function should be implemented in a way that self._original_predictions should be converted to a list of prediction.ObjectPredic
sahi/models/base.py:121
↓ 1 callersFunction_get_gt_area_group_numbers
(cocoEval)
sahi/scripts/coco_error_analysis.py:146
↓ 1 callersMethod_get_merged_bbox
(pred1: ObjectPrediction, pred2: ObjectPrediction)
sahi/postprocess/legacy/combine.py:158
↓ 1 callersMethod_get_merged_category
(pred1: ObjectPrediction, pred2: ObjectPrediction)
sahi/postprocess/legacy/combine.py:151
↓ 1 callersMethod_get_merged_mask
(pred1: ObjectPrediction, pred2: ObjectPrediction)
sahi/postprocess/legacy/combine.py:173
↓ 1 callersMethod_get_merged_score
( pred1: ObjectPrediction, pred2: ObjectPrediction, )
sahi/postprocess/legacy/combine.py:165
↓ 1 callersFunction_make_gt_area_group_numbers_plot
(cocoEval, outDir, verbose=True)
sahi/scripts/coco_error_analysis.py:161
↓ 1 callersFunction_make_gt_area_histogram_plot
(cocoEval, outDir)
sahi/scripts/coco_error_analysis.py:195
↓ 1 callersMethod_merge_object_prediction_pair
( self, pred1: ObjectPrediction, pred2: ObjectPrediction, )
sahi/postprocess/legacy/combine.py:124
↓ 1 callersMethod_multiclass_nms
( self, boxes, scores, nms_thr, score_thr, class_agnostic=True
yolox/yolox_onnx.py:186
↓ 1 callersMethod_postprocess
( self, outputs, img_size, ratio, nms_th, nms_score_th,
yolox/yolox_onnx.py:95
↓ 1 callersMethod_preprocess
(self, image, input_size, swap=(2, 0, 1))
yolox/yolox_onnx.py:72
↓ 1 callersMethodadd_category
Adds category to this CocoVid instance Args: category: CocoCategory
sahi/utils/coco.py:2128
↓ 1 callersMethodadd_sliced_image
(self, sliced_image: SlicedImage)
sahi/slicing.py:177
↓ 1 callersFunctionapp
Cli app.
sahi/cli.py:29
↓ 1 callersFunctionbatched_greedy_nmm
Apply greedy version of non-maximum merging per category to avoid detecting too many overlapping bounding boxes for a given object. Args:
sahi/postprocess/combine.py:150
↓ 1 callersFunctionbatched_nmm
Apply non-maximum merging per category to avoid detecting too many overlapping bounding boxes for a given object. Args: object_pr
sahi/postprocess/combine.py:304
↓ 1 callersFunctionbatched_nms
Apply non-maximum suppression to avoid detecting too many overlapping bounding boxes for a given object. Args: predictions: (tens
sahi/postprocess/combine.py:16
↓ 1 callersFunctioncalc_aspect_ratio_orientation
Args: width: height: Returns: image capture orientation
sahi/slicing.py:541
↓ 1 callersFunctioncalc_resolution_factor
According to image resolution calculate power(2,n) and return the closest smaller `n`. Args: resolution: the width and height of the
sahi/slicing.py:525
↓ 1 callersFunctioncalc_slice_and_overlap_params
This function calculate according to image resolution slice and overlap params. Args: resolution: str height: int wid
sahi/slicing.py:560
↓ 1 callersFunctioncalculate_bbox_ios
Returns the ratio of intersection area to the smaller box's area
sahi/postprocess/utils.py:137
↓ 1 callersFunctioncalculate_bbox_iou
Returns the ratio of intersection area to the union
sahi/postprocess/utils.py:127
↓ 1 callersMethodcalculate_stats
Iterates over all annotations and calculates total number of
sahi/utils/coco.py:1110
↓ 1 callersFunctioncheck_package_minimum_version
Raise error if module version is not compatible.
sahi/utils/import_utils.py:70
↓ 1 callersMethodconvert_original_predictions
Converts original predictions of the detection model to a list of prediction.ObjectPrediction object. Should be called after perform_
sahi/models/base.py:154
next →1–100 of 388, ranked by callers