MCPcopy Create free account

hub / github.com/VincentHancoder/SSGD / functions

Functions2,751 in github.com/VincentHancoder/SSGD

↓ 9 callersMethodpad
See :func:`BaseInstanceMasks.pad`.
mmdet/core/mask/structures.py:303
↓ 9 callersFunctionselect_single_mlvl
Extract a multi-scale single image tensor from a multi-scale batch tensor based on batch index. Note: The default value of detach is True, be
mmdet/core/utils/misc.py:88
↓ 8 callersFunction_construct_bbox
(num_bbox=None)
tests/test_metrics/test_box_overlap.py:13
↓ 8 callersFunctionbuild_anchor_generator
(cfg, default_args=None)
mmdet/core/anchor/builder.py:15
↓ 8 callersFunctionbuild_roi_extractor
Build roi extractor.
mmdet/models/builder.py:28
↓ 8 callersFunctioneval_map
Evaluate mAP of a dataset. Args: det_results (list[list]): [[cls1_det, cls2_det, ...], ...]. The outer list indicates images,
mmdet/core/evaluation/mean_ap.py:525
↓ 8 callersFunctionfilter_scores_and_topk
Filter results using score threshold and topk candidates. Args: scores (Tensor): The scores, shape (num_bboxes, K). score_thr (fl
mmdet/core/utils/misc.py:119
↓ 8 callersFunctionfpn_neck_config
Return the class containing the corresponding attributes according to the fpn_test_step_names.
tests/test_onnx/test_neck.py:35
↓ 8 callersFunctionlog_img_scale
Log image size. Args: img_scale (tuple): Image size to be logged. shape_order (str, optional): The order of image shape.
mmdet/utils/logger.py:37
↓ 8 callersMethodshow_result
Show RPN proposals on the image. Args: data (str or np.ndarray): Image filename or loaded image. result (Tensor or tu
mmdet/models/detectors/rpn.py:142
↓ 8 callersMethodsimple_test
Test function without test time augmentation. Args: imgs (list[torch.Tensor]): List of multiple images img_metas (lis
mmdet/models/detectors/rpn.py:91
↓ 8 callersMethodsparse_priors
Generate sparse anchors according to the ``prior_idxs``. Args: prior_idxs (Tensor): The index of corresponding anchors
mmdet/core/anchor/anchor_generator.py:283
↓ 8 callersFunctiontranspose_and_gather_feat
Transpose and gather feature according to index. Args: feat (Tensor): Target feature map. ind (Tensor): Target coord index.
mmdet/models/utils/gaussian_target.py:255
↓ 8 callersMethodvalid_flags
(self, featmap_size, valid_size, device='cuda')
mmdet/core/anchor/point_generator.py:30
↓ 8 callersFunctionwrapper
(pred, target, weight=None, reduction='mean',
mmdet/models/losses/utils.py:94
↓ 7 callersFunction_replace_r50_with_r18
Replace ResNet50 with ResNet18 in config.
tests/test_models/test_forward.py:46
↓ 7 callersFunctionbuild_backbone
Build backbone.
mmdet/models/builder.py:18
↓ 7 callersFunctionbuild_iou_calculator
Builder of IoU calculator.
mmdet/core/bbox/iou_calculators/builder.py:7
↓ 7 callersMethodbuild_trans
(self, cfg, in_channels, out_channels, **extra_args)
mmdet/models/necks/fpg.py:317
↓ 7 callersFunctioncompat_loader_args
Deprecated sample_per_gpu in cfg.data.
mmdet/utils/compat_config.py:54
↓ 7 callersMethoddecode
Apply transformation `pred_bboxes` to `boxes`. Args: bboxes (torch.Tensor): Basic boxes. Shape (B, N, 4) or (N, 4) pr
mmdet/core/bbox/coder/delta_xywh_bbox_coder.py:65
↓ 7 callersFunctionflip_tensor
flip tensor base on flip_direction. Args: src_tensor (Tensor): input feature map, shape (B, C, H, W). flip_direction (str): The f
mmdet/core/utils/misc.py:65
↓ 7 callersMethodformat_results
Format the results to json (standard format for COCO evaluation). Args: results (list[tuple | numpy.ndarray]): Testing results of
mmdet/datasets/ssgd.py:325
↓ 7 callersMethodget_ann_info
Get COCO annotation by index. Args: idx (int): Index of data. Returns: dict: Annotation info of specified in
mmdet/datasets/ssgd.py:58
↓ 7 callersMethodget_bboxes
(self, cls_scores, bbox_preds, score_factors=None,
mmdet/models/dense_heads/paa_head.py:521
↓ 7 callersFunctioninit_detector
Initialize a detector from config file. Args: config (str, :obj:`Path`, or :obj:`mmcv.Config`): Config file path, :obj:`Path`
mmdet/apis/inference.py:18
↓ 7 callersMethodload_anns
Load anns with the specified ids. self.anns is a list of annotation lists instead of a list of annotations. Args:
mmdet/datasets/coco_panoptic.py:89
↓ 7 callersFunctionmerge_aug_masks
Merge augmented mask prediction. Args: aug_masks (list[ndarray]): shape (n, #class, h, w) img_shapes (list[ndarray]): shape (3, )
mmdet/core/post_processing/merge_augs.py:121
↓ 7 callersMethodregress_by_class
Regress the bbox for the predicted class. Used in Cascade R-CNN. Args: rois (Tensor): Rois from `rpn_head` or last stage
mmdet/models/roi_heads/bbox_heads/bbox_head.py:460
↓ 7 callersMethodset_extra_property
Set user-defined new property.
mmdet/core/bbox/assigners/assign_result.py:56
↓ 7 callersMethodtrain
(self, mode=True)
mmdet/models/backbones/csp_darknet.py:269
↓ 6 callersMethod_bbox_post_process
bbox post-processing method. The boxes would be rescaled to the original image scale and do the nms operation. Usually with_nms is Fa
mmdet/models/dense_heads/paa_head.py:620
↓ 6 callersFunction_create_dummy_results
()
tests/test_data/test_datasets/test_common.py:96
↓ 6 callersFunctionadaptive_avg_pool2d
Handle empty batch dimension to adaptive_avg_pool2d. Args: input (tensor): 4D tensor. output_size (int, tuple[int,int]): the targ
mmdet/models/utils/brick_wrappers.py:15
↓ 6 callersFunctionbbox_overlaps
Calculate overlap between two set of bboxes. FP16 Contributed by https://github.com/open-mmlab/mmdetection/pull/4889 Note: Assume bbo
mmdet/core/bbox/iou_calculators/iou2d_calculator.py:75
↓ 6 callersFunctionbuild_dataloader
Build PyTorch DataLoader. In distributed training, each GPU/process has a dataloader. In non-distributed training, there is only one dataload
mmdet/datasets/builder.py:87
↓ 6 callersFunctionbuild_match_cost
Builder of IoU calculator.
mmdet/core/bbox/match_costs/builder.py:7
↓ 6 callersFunctionbuild_neck
Build neck.
mmdet/models/builder.py:23
↓ 6 callersFunctioncheck_norm_state
Check if norm layer is in correct train state.
tests/test_models/test_backbones/utils.py:26
↓ 6 callersMethoddecode
Apply transformation `pred_bboxes` to `boxes`. Args: bboxes (torch.Tensor): Basic boxes.Shape (B, N, 4) or (N, 4) pre
mmdet/core/bbox/coder/tblr_bbox_coder.py:50
↓ 6 callersFunctionfind_latest_checkpoint
Find the latest checkpoint from the working directory. Args: path(str): The path to find checkpoints. suffix(str): File extension
mmdet/utils/misc.py:11
↓ 6 callersMethodget_activation
Get custom activation of cls_score. Args: cls_score (torch.Tensor): The prediction with shape (N, C + 2). Returns:
mmdet/models/losses/seesaw_loss.py:157
↓ 6 callersMethodmake_block_plugins
make plugins for block. Args: in_channels (int): Input channels of plugin. plugins (list[dict]): List of plugins cfg
mmdet/models/backbones/resnet.py:219
↓ 6 callersMethodmeta_info_items
(self)
mmdet/core/data_structures/general_data.py:191
↓ 6 callersMethodmeta_info_keys
Returns: list: Contains all keys in meta_info_fields.
mmdet/core/data_structures/general_data.py:166
↓ 6 callersMethodrefine_bboxes
Refine bboxes during training. Args: rois (Tensor): Shape (n*bs, 5), where n is image number per GPU, and bs is t
mmdet/models/roi_heads/bbox_heads/bbox_head.py:381
↓ 6 callersMethodresize
see :func:`BaseInstanceMasks.resize`
mmdet/core/mask/structures.py:644
↓ 6 callersFunctionsetup_multi_processes
Setup multi-processing environment variables.
mmdet/utils/setup_env.py:10
↓ 6 callersMethodsimple_test_rpn
Simple forward test function.
mmdet/models/dense_heads/cascade_rpn_head.py:773
↓ 6 callersMethodto_tensor
See :func:`BaseInstanceMasks.to_tensor`.
mmdet/core/mask/structures.py:507
↓ 5 callersMethod__init__
(self, embed_dims, feedforward_channels, act_cfg=dict(type=
mmdet/models/backbones/pvt.py:47
↓ 5 callersMethod_bbox_forward
Box head forward function used in both training and testing.
mmdet/models/roi_heads/scnet_roi_head.py:96
↓ 5 callersMethod_bbox_forward
Box head forward function used in both training and testing.
mmdet/models/roi_heads/cascade_roi_head.py:130
↓ 5 callersFunction_demo_mm_inputs
Create a superset of inputs needed to run test or train batches. Args: input_shape (tuple): input batch dimensions n
tests/test_downstream/test_mmtrack.py:152
↓ 5 callersFunction_dummy_bbox_sampling
Create sample results that can be passed to BBoxHead.get_targets.
tests/test_models/test_roi_heads/utils.py:7
↓ 5 callersMethod_freeze_stages
(self)
mmdet/models/backbones/resnet.py:613
↓ 5 callersMethod_mask_forward
Mask head forward function used in both training and testing.
mmdet/models/roi_heads/cascade_roi_head.py:158
↓ 5 callersFunctionadd_dummy_nms_for_onnx
Create a dummy onnx::NonMaxSuppression op while exporting to ONNX. This function helps exporting to onnx with batch and multiclass NMS op. It
mmdet/core/export/onnx_helper.py:82
↓ 5 callersFunctioncheck_translate
(results, results_translated, offset,
tests/test_data/test_pipelines/test_transform/test_translate.py:335
↓ 5 callersMethodcrop
See :func:`BaseInstanceMasks.crop`.
mmdet/core/mask/structures.py:314
↓ 5 callersFunctionencode_mask_results
Encode bitmap mask to RLE code. Args: mask_results (list | tuple[list]): bitmap mask results. In mask scoring rcnn, mask_resu
mmdet/core/mask/utils.py:38
↓ 5 callersMethodextract_feat
Directly extract features from the backbone+neck.
mmdet/models/detectors/two_stage.py:65
↓ 5 callersMethodextract_feats
Extract features from multiple images. Args: imgs (list[torch.Tensor]): A list of images. The images are augmente
mmdet/models/detectors/base.py:50
↓ 5 callersFunctiongenerate_coordinate
Generate the coordinate. Args: featmap_sizes (tuple): The feature to be calculated, of shape (N, C, W, H). device (st
mmdet/core/utils/misc.py:190
↓ 5 callersMethodget_cat_ids
Get category ids of concatenated dataset by index. Args: idx (int): Index of data. Returns: list[int]: All c
mmdet/datasets/dataset_wrappers.py:50
↓ 5 callersMethodget_cat_ids
Get COCO category ids by index. Args: idx (int): Index of data. Returns: list[int]: All categories in the im
mmdet/datasets/ssgd.py:73
↓ 5 callersMethodget_extra_property
Get user-defined property.
mmdet/core/bbox/assigners/assign_result.py:61
↓ 5 callersMethodget_img_ids
(self, img_ids=[], cat_ids=[])
mmdet/datasets/api_wrappers/coco_api.py:33
↓ 5 callersFunctioninference_detector
Inference image(s) with the detector. Args: model (nn.Module): The loaded detector. imgs (str/ndarray or list[str/ndarray] or tup
mmdet/apis/inference.py:93
↓ 5 callersFunctioninterpolate_as
Interpolate the `source` to the shape of the `target`. The `source` must be a Tensor, but the `target` can be a Tensor or a np.ndarray with t
mmdet/models/utils/misc.py:35
↓ 5 callersMethodload_imgs
(self, ids)
mmdet/datasets/api_wrappers/coco_api.py:42
↓ 5 callersFunctionmake_divisible
Make divisible function. This function rounds the channel number to the nearest value that can be divisible by the divisor. It is taken from
mmdet/models/utils/make_divisible.py:2
↓ 5 callersFunctionmerge_aug_bboxes
Merge augmented detection bboxes and scores. Args: aug_bboxes (list[Tensor]): shape (n, 4*#class) aug_scores (list[Tensor] or Non
mmdet/core/post_processing/merge_augs.py:84
↓ 5 callersMethodnorm3
nn.Module: normalization layer after the third convolution layer
mmdet/models/backbones/resnet.py:259
↓ 5 callersFunctionparse_requirements
Parse the package dependencies listed in a requirements file but strips specific versioning information. Args: fname (str): path to r
setup.py:56
↓ 5 callersMethodpre_pipeline
Prepare results dict for pipeline.
mmdet/datasets/custom.py:167
↓ 5 callersMethodretry_if_cuda_oom
Makes a function retry itself after encountering pytorch's CUDA OOM error. The implementation logic is referred to https://gi
mmdet/utils/memory.py:124
↓ 5 callersMethodset_data
Update a dict to `data_fields`. Args: data (dict): A dict contains annotations of image or model predictions. Def
mmdet/core/data_structures/general_data.py:129
↓ 5 callersFunctionto_tensor
Convert objects of various python types to :obj:`torch.Tensor`. Supported types are: :class:`numpy.ndarray`, :class:`torch.Tensor`, :class:`S
mmdet/datasets/pipelines/formatting.py:12
↓ 4 callersMethod__init__
(self, embed_dims, num_heads, window_size,
mmdet/models/backbones/swin.py:41
↓ 4 callersMethod__init__
(self, linear=False, eps=1e-6, reduction='mean',
mmdet/models/losses/iou_loss.py:256
↓ 4 callersMethod_bbox_forward
Box head forward function used in both training and testing.
mmdet/models/roi_heads/htc_roi_head.py:158
↓ 4 callersFunction_check_fields
Check data in fields from two results are same.
tests/test_data/test_pipelines/test_transform/utils.py:7
↓ 4 callersFunction_context_for_ohem
()
tests/test_data/test_pipelines/test_sampler.py:95
↓ 4 callersFunction_create_dummy_results
()
tests/test_data/test_datasets/test_openimages_dataset.py:120
↓ 4 callersFunction_forward_train
()
tests/test_models/test_forward.py:855
↓ 4 callersFunction_ignore_torch_cuda_oom
A context which ignores CUDA OOM exception from pytorch. Code is modified from <https://github.com/facebookresearch/detectron2/blob/main/dete
mmdet/utils/memory.py:63
↓ 4 callersMethod_mask_forward
Mask head forward function used in both training and testing.
mmdet/models/roi_heads/standard_roi_head.py:181
↓ 4 callersFunction_pad
(h, w, c, pad_val, axis=-1, dtype=np.float32)
tests/test_data/test_pipelines/test_transform/test_translate.py:20
↓ 4 callersFunctionanchor_ctr_inside_region_flags
Get the flag indicate whether anchor centers are inside regions.
mmdet/core/bbox/assigners/region_assigner.py:27
↓ 4 callersFunctionarea
(bboxes)
tests/test_data/test_pipelines/test_transform/test_transform.py:245
↓ 4 callersMethodbackward
(ctx, grad_output)
mmdet/models/utils/misc.py:25
↓ 4 callersFunctionbbox_mapping_back
Map bboxes from testing scale to original image scale.
mmdet/core/bbox/transforms.py:63
↓ 4 callersFunctionbuild_linear_layer
Build linear layer. Args: cfg (None or dict): The linear layer config, which should contain: - type (str): Layer type.
mmdet/models/utils/builder.py:17
↓ 4 callersFunctioncalc_region
Calculate region of the box defined by the ratio, the ratio is from the center of the box to every edge.
mmdet/core/bbox/assigners/region_assigner.py:10
↓ 4 callersFunctioncalc_region
Calculate a proportional bbox region. The bbox center are fixed and the new h' and w' is h * ratio and w * ratio. Args: bbox (Tensor
mmdet/core/anchor/utils.py:50
↓ 4 callersFunctiondummy_bboxes
(num, max_height, max_width)
tests/test_utils/test_masks.py:36
↓ 4 callersFunctiondummy_masks
(h, w, num_obj=3, mode='bitmap')
tests/test_runtime/test_config.py:271
↓ 4 callersFunctiondynamic_clip_for_onnx
Clip boxes dynamically for onnx. Since torch.clamp cannot have dynamic `min` and `max`, we scale the boxes by 1/max_shape and clamp in the
mmdet/core/export/onnx_helper.py:7
↓ 4 callersFunctionensure_rng
Coerces input into a random number generator. If the input is None, then a global random state is returned. If the input is a numeric value,
mmdet/utils/util_random.py:6
← previousnext →101–200 of 2,751, ranked by callers