MCPcopy Create free account

hub / github.com/JialianW/GRiT / functions

Functions187 in github.com/JialianW/GRiT

↓ 8 callersMethod__init__
(self, config)
grit/modeling/text/modeling_bert.py:210
↓ 7 callersMethodstep
(self, closure=None)
grit/custom_solver.py:45
↓ 6 callersFunctionbuild_custom_augmentation
Create a list of default :class:`Augmentation` from config. Now it includes resizing and flipping. Returns: list[Augmentation]
grit/data/custom_build_augmentation.py:6
↓ 5 callersMethod__init__
(self, visual_feature_size: int, vocab_size: int, hidden_size: int)
grit/modeling/text/text_decoder.py:12
↓ 4 callersMethod__init__
Args: img_size (int): Input image size. patch_size (int): Patch size. in_chans (int): Number of input ima
grit/modeling/backbone/vit.py:244
↓ 3 callersFunctionadd_grit_config
(cfg)
grit/config.py:4
↓ 3 callersMethodtranspose_for_scores
(self, x)
grit/modeling/text/modeling_bert.py:91
↓ 2 callersMethod_forward_box
(self, features, proposals, targets=None, task="ObjectDet")
grit/modeling/roi_heads/grit_roi_heads.py:151
↓ 2 callersFunctionbuild_custom_optimizer
(cfg: CfgNode, model: torch.nn.Module)
grit/custom_solver.py:12
↓ 2 callersFunctionbuild_custom_train_loader
( dataset, *, mapper, sampler, total_batch_size=16, num_workers=0, num_datase
grit/data/custom_dataset_dataloader.py:70
↓ 2 callersMethodcheck_if_all_background
(self, proposals, targets, stage)
grit/modeling/roi_heads/grit_roi_heads.py:134
↓ 2 callersMethodcollate
(self, batch)
grit/modeling/text/load_text_token.py:54
↓ 2 callersFunctiondo_test
(cfg, model)
train_deepspeed.py:55
↓ 2 callersFunctiondo_test
(cfg, model)
train_net.py:52
↓ 2 callersFunctionget_mpi_local_rank
()
lauch_deepspeed.py:148
↓ 2 callersFunctionget_rel_pos
Get relative positional embeddings according to the relative positions of query and key sizes. Args: q_size (int): size of qu
grit/modeling/backbone/utils.py:63
↓ 2 callersFunctioninstances_to_coco_json
Add object_descriptions and logit (if applicable) to detectron2's instances_to_coco_json
grit/evaluation/eval.py:125
↓ 2 callersFunctionmaybe_add_full_model_gradient_clipping
(optim)
grit/custom_solver.py:35
↓ 2 callersMethodprepare_data
(self, dataset_dict_in)
grit/data/custom_dataset_mapper.py:67
↓ 2 callersFunctionsplit_s3_path
Split a full s3 path into the bucket name and path.
grit/modeling/text/file_utils.py:122
↓ 2 callersMethodto_json_string
Serializes this instance to a JSON string.
grit/modeling/text/modeling_bert.py:448
↓ 1 callersMethod__init__
(self, object_descriptions)
grit/data/custom_dataset_mapper.py:130
↓ 1 callersMethod_create_position_indices
(self, tokens: torch.Tensor)
grit/modeling/text/text_decoder.py:62
↓ 1 callersMethod_create_proposals_from_boxes
(self, boxes, image_sizes, logits)
grit/modeling/roi_heads/grit_roi_heads.py:457
↓ 1 callersFunction_find_free_port
()
lauch_deepspeed.py:16
↓ 1 callersMethod_generate_future_mask
( self, size: int, dtype: torch.dtype, device: torch.device )
grit/modeling/text/text_decoder.py:345
↓ 1 callersMethod_get_empty_mask_loss
(self, device)
grit/modeling/roi_heads/grit_roi_heads.py:450
↓ 1 callersMethod_infinite_indices
(self)
grit/data/custom_dataset_dataloader.py:195
↓ 1 callersMethod_match_and_label_boxes_GRiT
Add "gt_object_description" and "foreground" to detectron2's _match_and_label_boxes
grit/modeling/roi_heads/grit_roi_heads.py:316
↓ 1 callersMethod_run_stage
(self, features, proposals, stage)
grit/modeling/roi_heads/grit_roi_heads.py:473
↓ 1 callersFunction_soft_nms
Soft non-max suppression algorithm. Implementation of [Soft-NMS -- Improving Object Detection With One Line of Codec] (https://arxiv.org
grit/modeling/soft_nms.py:99
↓ 1 callersFunctionadd_decomposed_rel_pos
Calculate decomposed Relative Positional Embeddings from :paper:`mvitv2`. https://github.com/facebookresearch/mvit/blob/19786631e330df9f3622e
grit/modeling/backbone/utils.py:96
↓ 1 callersMethodapply_image
(self, img, interp=None)
grit/data/transforms/custom_transform.py:47
↓ 1 callersFunctionbatched_soft_nms
Performs soft non-maximum suppression in a batched fashion. Each index value correspond to a category, and NMS will not be applied betwe
grit/modeling/soft_nms.py:47
↓ 1 callersMethodbox_reg_loss
( self, proposal_boxes, gt_boxes, pred_deltas, gt_classes, num_classes=-1)
grit/modeling/roi_heads/grit_fast_rcnn.py:80
↓ 1 callersFunctionbuild_dataset_batch_data_loader
( dataset_bs, dataset, sampler, total_batch_size, num_datasets, num_workers=0 )
grit/data/custom_dataset_dataloader.py:96
↓ 1 callersFunctioncached_path
Given something that might be a URL (or might be a local path), determine which. If it's a URL, download the file and cache it, and retur
grit/modeling/text/file_utils.py:92
↓ 1 callersMethodconvert_classname_to_id
(self, results)
grit/evaluation/eval.py:69
↓ 1 callersFunctioncreate_transformer
(decoder_type, norm_type, textual_feature_size, attention_heads,
grit/modeling/text/text_decoder.py:156
↓ 1 callersMethoddescriptions_to_text_tokens
(self, target, begin_token)
grit/modeling/text/load_text_token.py:10
↓ 1 callersFunctiondo_train
(cfg, model, resume=False, train_batch_size=1)
train_deepspeed.py:118
↓ 1 callersFunctiondo_train
(cfg, model, resume=False)
train_net.py:81
↓ 1 callersMethoddraw_instance_predictions
(self, predictions)
grit/predictor.py:13
↓ 1 callersMethodfast_rcnn_inference_GRiT
( self, boxes: List[torch.Tensor], scores: List[torch.Tensor],
grit/modeling/roi_heads/grit_roi_heads.py:362
↓ 1 callersMethodfast_rcnn_inference_single_image_GRiT
Add soft NMS to detectron2's fast_rcnn_inference_single_image
grit/modeling/roi_heads/grit_roi_heads.py:383
↓ 1 callersMethodfrom_dict
Constructs a `Config` from a Python dictionary of parameters.
grit/modeling/text/modeling_bert.py:423
↓ 1 callersMethodfrom_json_file
Constructs a `BertConfig` from a json file of parameters.
grit/modeling/text/modeling_bert.py:431
↓ 1 callersMethodfrom_pretrained
r""" Instantiate a PretrainedConfig from a pre-trained model configuration. Params: **pretrained_model_name_or_path**: either:
grit/modeling/text/modeling_bert.py:327
↓ 1 callersFunctionget_GRiTcoco_meta
()
grit/data/datasets/grit_coco.py:25
↓ 1 callersFunctionget_abs_pos
Calculate absolute positional embeddings. If needed, resize embeddings and remove cls_token dimension for the original embeddings. Ar
grit/modeling/backbone/utils.py:128
↓ 1 callersFunctionget_deep_speed_config
(train_batch_size)
train_deepspeed.py:84
↓ 1 callersFunctionget_detection_dataset_dicts_with_source
( dataset_names, filter_empty=True, min_keypoints=0, proposal_files=None )
grit/data/custom_dataset_dataloader.py:122
↓ 1 callersFunctionget_from_cache
Given a URL, look for the corresponding dataset in the local cache. If it's not there, download it. Then return the path to the cached file.
grit/modeling/text/file_utils.py:183
↓ 1 callersFunctionget_master_node_ip
()
train_deepspeed.py:104
↓ 1 callersFunctionget_mpi_rank
()
lauch_deepspeed.py:136
↓ 1 callersFunctionget_mpi_size
()
lauch_deepspeed.py:142
↓ 1 callersFunctionget_o365_meta
()
grit/data/datasets/object365.py:23
↓ 1 callersFunctionget_parser
()
demo.py:44
↓ 1 callersFunctionget_vg_meta
()
grit/data/datasets/vg.py:25
↓ 1 callersFunctionget_vit_lr_decay_rate
Calculate lr decay rate for different ViT blocks. Args: name (string): parameter name. lr_decay_rate (float): base lr decay r
grit/custom_solver.py:70
↓ 1 callersFunctionhttp_get
(url, temp_file)
grit/modeling/text/file_utils.py:171
↓ 1 callersMethodinfer
(self, object_features)
grit/modeling/text/text_decoder.py:600
↓ 1 callersMethodinference
( self, batched_inputs: Tuple[Dict[str, torch.Tensor]], detected_instances: Optional[L
grit/modeling/meta_arch/grit.py:23
↓ 1 callersMethodinverse_apply_coords
(self, coords)
grit/data/transforms/custom_transform.py:98
↓ 1 callersFunctionlaunch_deepspeed
Modified by Jialian Wu from https://github.com/facebookresearch/detectron2/blob/main/detectron2/engine/launch.py Launch multi-gpu or distribu
lauch_deepspeed.py:28
↓ 1 callersFunctionlaunch_deepspeed_multinodes
Launch multi-node training via deepspeed.
lauch_deepspeed.py:154
↓ 1 callersFunctionload_GRiTcoco_json
Load COCO class name text for object description for GRiT
grit/data/datasets/grit_coco.py:33
↓ 1 callersFunctionload_o365_json
Load Object365 class name text for object description for GRiT
grit/data/datasets/object365.py:31
↓ 1 callersFunctionload_vg_json
(json_file, image_root, dataset_name=None)
grit/data/datasets/vg.py:33
↓ 1 callersMethodlosses
(self, predictions, proposals)
grit/modeling/roi_heads/grit_fast_rcnn.py:46
↓ 1 callersMethodpredict_probs
(self, predictions, proposals)
grit/modeling/roi_heads/grit_fast_rcnn.py:110
↓ 1 callersFunctionqk2attn
(query, key, attention_mask, gamma)
grit/modeling/text/modeling_bert.py:53
↓ 1 callersFunctionregister_GRiTcoco_instances
grit/data/datasets/grit_coco.py:14
↓ 1 callersFunctionregister_o365_instances
(name, metadata, json_file, image_root)
grit/data/datasets/object365.py:14
↓ 1 callersFunctionregister_vg_instances
grit/data/datasets/vg.py:14
↓ 1 callersMethodrun_on_image
(self, image)
grit/predictor.py:58
↓ 1 callersFunctions3_etag
Check ETag on S3 object.
grit/modeling/text/file_utils.py:155
↓ 1 callersFunctions3_get
Pull a file directly from S3.
grit/modeling/text/file_utils.py:164
↓ 1 callersMethodsearch
(self, begin_tokens, step)
grit/modeling/text/text_decoder.py:371
↓ 1 callersFunctionsetup
Create configs and perform basic setups.
train_deepspeed.py:216
↓ 1 callersFunctionsetup
Create configs and perform basic setups.
train_net.py:172
↓ 1 callersFunctionsetup_cfg
(args)
demo.py:24
↓ 1 callersFunctionsoft_nms
Performs soft non-maximum suppression algorithm on axis aligned boxes Args: boxes (Tensor[N, 5]): boxes where NMS will be
grit/modeling/soft_nms.py:6
↓ 1 callersMethodsoftmax_cross_entropy_loss
(self, pred_class_logits, gt_classes)
grit/modeling/roi_heads/grit_fast_rcnn.py:72
↓ 1 callersMethodto_dict
Serializes this instance to a Python dictionary.
grit/modeling/text/modeling_bert.py:443
↓ 1 callersMethodto_json_file
Save this instance to a json file.
grit/modeling/text/modeling_bert.py:452
↓ 1 callersFunctionurl_to_filename
Convert `url` into a hashed filename in a repeatable way. If `etag` is specified, append its hash to the url's, delimited by a period.
grit/modeling/text/file_utils.py:48
↓ 1 callersFunctionwindow_partition
Partition into non-overlapping windows with padding if needed. Args: x (tensor): input tokens with [B, H, W, C]. window_size
grit/modeling/backbone/utils.py:16
↓ 1 callersFunctionwindow_unpartition
Window unpartition into original sequences and removing padding. Args: x (tensor): input tokens with [B * num_windows, window_size, w
grit/modeling/backbone/utils.py:40
Method__call__
(self, object_descriptions, box_features, begin_token)
grit/modeling/text/load_text_token.py:33
Method__call__
(self, dataset_dict)
grit/data/custom_dataset_mapper.py:52
Method__eq__
(self, other)
grit/modeling/text/modeling_bert.py:437
Method__getitem__
(self, item)
grit/data/custom_dataset_mapper.py:133
Method__init__
(self, image, instance_mode=None)
grit/predictor.py:10
Method__init__
(self, cfg, instance_mode=ColorMode.IMAGE)
grit/predictor.py:52
Method__init__
Args: dim (int): Number of input channels. num_heads (int): Number of attention heads. qkv_bias (bool: I
grit/modeling/backbone/vit.py:35
Method__init__
Args: in_channels (int): Number of input channels. out_channels (int): Number of output channels. bottlen
grit/modeling/backbone/vit.py:97
Method__init__
Args: dim (int): Number of input channels. num_heads (int): Number of attention heads in each ViT block.
grit/modeling/backbone/vit.py:155
Method__init__
(self, bottom_up=None, top_block=None, out_channels=None, strides=None, vit_out_dim=None)
grit/modeling/backbone/vit.py:367
Method__init__
Args: kernel_size (Tuple): kernel size of the projection layer. stride (Tuple): stride of the projection layer.
grit/modeling/backbone/utils.py:165
next →1–100 of 187, ranked by callers