MCPcopy Create free account

hub / github.com/CAIR-HKISI/SurgMotion / functions

Functions2,319 in github.com/CAIR-HKISI/SurgMotion

↓ 4 callersFunction_get_param_spatial_crop
Given scale, ratio, height and width, return sampled coordinates of the videos.
src/datasets/utils/video/transforms.py:470
↓ 4 callersMethod_make_layer
(self, block, planes, blocks, shortcut_type, stride=1)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/r3d.py:220
↓ 4 callersFunction_make_vjepa2_model
( *, model_name: str = "vit_large", img_size=256, patch_size=16, tubelet_size=2, num_f
src/hub/backbones.py:83
↓ 4 callersMethod_params_per_elem
(self, batch_size)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/transforms/mixup.py:121
↓ 4 callersMethod_params_per_elem
(self, batch_size)
foundation_models/EndoMamba/videomamba/video_sm/datasets/mixup.py:121
↓ 4 callersFunctioncaformer_s18
(num_classes=0, pretrained='ImageNet', pretrained_weights=None, **kwargs)
foundation_models/SurgeNet/metaformer.py:666
↓ 4 callersFunctionconvnextv2_tiny
(**kwargs)
foundation_models/SurgeNet/convnextv2.py:225
↓ 4 callersFunctiongrayscale
Convert the image to gray scale. Args: image (tensor): image to convert to gray scale. Dimension is `channel` x `height`
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/cv2_transform.py:635
↓ 4 callersFunctionhorizontal_flip
Perform horizontal flip on the given images and corresponding boxes. Args: prob (float): probility to flip the images. images
foundation_models/EndoMamba/videomamba/video_sm/datasets/video_transforms.py:155
↓ 4 callersFunctionload_and_apply_checkpoint
One-stop checkpoint loading and applying function. Args: model: Model to load weights into checkpoint_path: Checkpoint p
evals/foundation_phase_probing/modelcustom/adapters/utils.py:154
↓ 4 callersFunctionload_pretrained
(model, cfg=None, num_classes=1000, in_chans=3, filter_fn=None, img_size=224, num_frames=8,
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/helpers.py:96
↓ 4 callersFunctionload_specific_model
(model, model_ema, args, output_dir, model_name)
foundation_models/EndoMamba/videomamba/video_sm/utils.py:604
↓ 4 callersMethodlocal_transform
(self, frames)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:719
↓ 4 callersMethodno_aug
(self, frames)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:694
↓ 4 callersFunctionpvt_v2_b2
(**kwargs)
foundation_models/SurgeNet/pvtv2.py:415
↓ 4 callersFunctionrandom_crop
Perform random spatial crop on the given images and corresponding boxes. Args: images (tensor): images to perform random crop. The di
foundation_models/EndoMamba/videomamba/video_sm/datasets/video_transforms.py:119
↓ 4 callersMethodreset
Reset the metric.
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/utils/meters.py:74
↓ 4 callersMethodreset
Reset the metric.
foundation_models/EndoMamba/videomamba/downstream/CVC-12kSegmentation/utils/meters.py:74
↓ 4 callersFunctionscale
Scale the short side of the image to size. Args: size (int): size to scale the image. image (array): image to perform short s
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/cv2_transform.py:76
↓ 4 callersFunctionuniform_crop
Perform uniform spatial sampling on the images and corresponding boxes. Args: images (tensor): images to perform uniform crop. The di
foundation_models/EndoMamba/videomamba/video_sm/datasets/video_transforms.py:190
↓ 4 callersMethodupdate
(self, head="scalar", step=None, **kwargs)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/utils.py:225
↓ 4 callersMethodupdate
(self, **kwargs)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/utils/utils.py:299
↓ 4 callersMethodupdate
(self, value, n=1)
foundation_models/EndoMamba/videomamba/video_sm/utils.py:35
↓ 4 callersMethodwriterow
Write row to internal buffers.
src/datasets/utils/dataloader.py:51
↓ 3 callersMethod__init__
(self, input_dim, output_dim, kernel_size, str
foundation_models/SurgVLP/surgvlp/codes/models/backbones/img_basicblocks.py:73
↓ 3 callersMethod__init__
(self, block, layers, block_inplanes, n_in
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/r3d.py:152
↓ 3 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection" This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/video_sm/models/videomamba_pretrain.py:30
↓ 3 callersMethod__init__
( self, num_queries=1, embed_dim=768, num_heads=12, mlp_ratio=4.0,
src/models/attentive_pooler.py:19
↓ 3 callersMethod__len__
(self)
foundation_models/EndoMamba/videomamba/video_sm/datasets/kinetics.py:306
↓ 3 callersMethod__len__
(self)
foundation_models/EndoMamba/videomamba/video_sm/datasets/ssv2.py:323
↓ 3 callersMethod__len__
(self)
foundation_models/EndoMamba/videomamba/video_sm/datasets/ssv2.py:599
↓ 3 callersMethod__len__
(self)
foundation_models/EndoMamba/videomamba/video_sm/datasets/lvu.py:357
↓ 3 callersMethod__len__
(self)
foundation_models/EndoMamba/videomamba/video_sm/datasets/kinetics_sparse.py:294
↓ 3 callersFunction_pil_interp
(method)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/transforms/video_transforms.py:33
↓ 3 callersFunction_pil_interp
(method)
foundation_models/EndoMamba/videomamba/video_sm/datasets/video_transforms.py:32
↓ 3 callersFunction_run
(command)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/utils/utils.py:387
↓ 3 callersMethod_video_batch_loader
(self, duration, indice, video_id, index, cut_black)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/phase/AutoLaparo_phase.py:497
↓ 3 callersMethod_video_batch_loader
(self, duration, indice, video_id, index, cut_black)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/phase/Cholec80_phase.py:475
↓ 3 callersMethod_video_batch_loader_for_key_frames
(self, duration, timestamp, video_id, index, cut_black)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/phase/AutoLaparo_phase.py:550
↓ 3 callersMethod_video_batch_loader_for_key_frames
(self, duration, timestamp, video_id, index, cut_black)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/phase/Cholec80_phase.py:525
↓ 3 callersFunctionblend
Blend two images with a given weight alpha. Args: images1 (tensor): the first images to be blended, the dimension is `num
foundation_models/SurgVLP/surgvlp/codes/datasets/transform.py:276
↓ 3 callersFunctionblend
Blend two images with a given weight alpha. Args: images1 (tensor): the first images to be blended, the dimension is `num
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/transforms/video_transforms.py:276
↓ 3 callersFunctionblend
Blend two images with a given weight alpha. Args: images1 (tensor): the first images to be blended, the dimension is `num
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:333
↓ 3 callersFunctionblend
Blend two images with a given weight alpha. Args: images1 (tensor): the first images to be blended, the dimension is `num
foundation_models/EndoMamba/videomamba/video_sm/datasets/video_transforms.py:275
↓ 3 callersFunctionblend
Blend two images with a given weight alpha. Args: images1 (tensor): the first images to be blended, the dimension is `num
src/datasets/utils/video/transforms.py:261
↓ 3 callersFunctionbuild_pretraining_dataset
(args)
foundation_models/EndoMamba/videomamba/video_sm/datasets/build.py:151
↓ 3 callersFunctionconv1x1x1
(in_planes, out_planes, stride=1)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/r3d.py:70
↓ 3 callersFunctionconv3x3x3
(in_planes, out_planes, stride=1)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/r3d.py:61
↓ 3 callersFunctioncrop_boxes
Peform crop on the bounding boxes given the offsets. Args: boxes (ndarray or None): bounding boxes to peform crop. The dimension
foundation_models/SurgVLP/surgvlp/codes/datasets/transform.py:65
↓ 3 callersFunctioncrop_boxes
Peform crop on the bounding boxes given the offsets. Args: boxes (ndarray or None): bounding boxes to peform crop. The dimension
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:79
↓ 3 callersFunctiondecode
Decode the video and perform temporal sampling. Args: container (container): pyav container. sampling_rate (int): frame sampl
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/decoder.py:303
↓ 3 callersMethodflip_and_color_jitter
(frames)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:670
↓ 3 callersMethodforward_features
(self, x)
foundation_models/SurgeNet/convnextv2.py:198
↓ 3 callersMethodgaussian_blur
(self, frames)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:683
↓ 3 callersFunctionget_1d_sincos_pos_embed
embed_dim: output dimension for each position grid_size: int of the grid length returns: pos_embed: [grid_size, embed_dim] (w/o c
src/models/utils/pos_embs.py:60
↓ 3 callersFunctionget_2d_sincos_pos_embed
grid_size: int of the grid height and width returns: pos_embed: [grid_size*grid_size, embed_dim] (w/o cls_token) or [
src/models/utils/pos_embs.py:41
↓ 3 callersFunctionget_3d_sincos_pos_embed
grid_size: int of the grid height and width grid_depth: int of the grid depth returns: pos_embed: [grid_depth*grid_size*grid_size
src/models/utils/pos_embs.py:9
↓ 3 callersFunctionget_parameter_groups
( model, weight_decay=1e-5, skip_list=(), get_num_layer=None, get_layer_scale=None, )
foundation_models/EndoMamba/videomamba/video_sm/optim_factory.py:59
↓ 3 callersMethodget_params
(self, brightness, contrast, saturation, hue)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/datasets/transforms/video_transforms.py:1194
↓ 3 callersFunctionget_random_sampling_rate
When multigrid training uses a fewer number of frames, we randomly increase the sampling rate so that some clips cover the original span.
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/data_utils.py:328
↓ 3 callersFunctionget_sinusoid_encoding_table
Sinusoid position encoding table
foundation_models/EndoMamba/videomamba/video_sm/models/modeling_finetune.py:158
↓ 3 callersFunctionget_start_end_idx
Sample a clip of size clip_size from a video of size video_size and return the indices of the first and last frame of the clip. If clip_idx i
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/decoder.py:30
↓ 3 callersFunctionget_video_container
Given the path to the video, return the pyav video container. Args: path_to_vid (str): path to the video. multi_thread_decode
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/video_container.py:6
↓ 3 callersMethodglobal_transform1
(self, frames)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:700
↓ 3 callersFunctiongrayscale
Get the grayscale for the input images. The channels of images should be in order BGR. Args: images (tensor): the input images fo
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:349
↓ 3 callersFunctionis_dist_avail_and_initialized
()
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/utils.py:272
↓ 3 callersFunctionis_dist_avail_and_initialized
()
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/utils/utils.py:404
↓ 3 callersFunctionis_dist_avail_and_initialized
()
foundation_models/EndoMamba/videomamba/video_sm/utils.py:320
↓ 3 callersFunctionload_state_dict
Load a state dict into the model, handling 2D to 3D weight inflation if necessary. Args: model (nn.Module): The model to load the st
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/model/endomamba.py:532
↓ 3 callersFunctionload_state_dict
(checkpoint_path, use_ema=False)
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/helpers.py:17
↓ 3 callersFunctionload_state_dict
Load a state dict into the model, handling 2D to 3D weight inflation if necessary. Args: model (nn.Module): The model to load the st
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/endomamba_classification.py:543
↓ 3 callersFunctionload_state_dict
Load a state dict into the model, handling 2D to 3D weight inflation if necessary. Args: model (nn.Module): The model to load the st
foundation_models/EndoMamba/videomamba/downstream/CVC-12kSegmentation/networks/endomamba_seg_modeling.py:219
↓ 3 callersFunctionload_state_dict
(model, state_dict, center=True)
foundation_models/EndoMamba/videomamba/video_sm/models/videomamba.py:411
↓ 3 callersFunctionload_state_dict
(model, state_dict, input_resolution=224, patch_size=16, center=True)
foundation_models/EndoMamba/videomamba/video_sm/models/clip.py:197
↓ 3 callersFunctionload_state_dict
(model, state_dict, center=True)
foundation_models/EndoMamba/videomamba/video_sm/models/videomamba_custom.py:420
↓ 3 callersFunctionload_state_dict
Load a state dict into the model, handling 2D to 3D weight inflation if necessary. Args: model (nn.Module): The model to load the st
foundation_models/EndoMamba/videomamba/video_sm/models/endomamba_two_heads.py:574
↓ 3 callersFunctionload_state_dict
Load a state dict into the model, handling 2D to 3D weight inflation if necessary. Args: model (nn.Module): The model to load the st
foundation_models/EndoMamba/videomamba/video_sm/models/endomamba.py:534
↓ 3 callersFunctionload_state_dict
Load a state dict into the model, handling 2D to 3D weight inflation if necessary. Args: model (nn.Module): The model to load the st
foundation_models/EndoMamba/videomamba/video_sm/models/endomamba_pretrain.py:499
↓ 3 callersMethodno_weight_decay
(self)
foundation_models/EndoMamba/videomamba/video_sm/models/endomamba.py:506
↓ 3 callersFunctionrandom_resized_crop
(images, size, scale, ratio=(3. / 4., 4. / 3.), interpolation='bilinear')
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:134
↓ 3 callersFunctionresize
(images, size, mode="bilinear")
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/transform.py:66
↓ 3 callersFunctionset_conv_params_fwd
foundation_models/EndoMamba/videomamba/causal-conv1d/csrc/causal_conv1d.cpp:55
↓ 3 callersFunctionspatial_sampling
Perform spatial sampling on the given video frames. If spatial_idx is -1, perform random scale, random crop, and random flip on the given
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/data_utils.py:109
↓ 3 callersMethodstop
(self)
src/utils/monitoring.py:64
↓ 3 callersMethodsynchronize_between_processes
(self)
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/utils.py:117
↓ 3 callersFunctiontensor_normalize
Normalize a given tensor by subtracting the mean and dividing the std. Args: tensor (tensor): tensor to normalize. mean (tens
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/datasets/data_utils.py:308
↓ 2 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection. This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/downstream/SurgicalPhase/Surgformer/model/endomamba.py:33
↓ 2 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection. This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/downstream/PolypDiagClassification/models/endomamba_classification.py:34
↓ 2 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection" This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/video_sm/models/videomamba.py:46
↓ 2 callersMethod__init__
( self, width, layers, heads, return_attn=False, clip_return_layer=1, clip_return_int
foundation_models/EndoMamba/videomamba/video_sm/models/clip.py:66
↓ 2 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection" This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/video_sm/models/videomamba_custom.py:39
↓ 2 callersMethod__init__
(self, img_size=224, patch_size=16, embed_dim=192,
foundation_models/EndoMamba/videomamba/video_sm/models/modeling_pretrain.py:192
↓ 2 callersMethod__init__
(self, num_classes=768, embed_dim=768, norm_layer=nn.LayerNorm, clip_norm_type='l2')
foundation_models/EndoMamba/videomamba/video_sm/models/modeling_pretrain_umt.py:136
↓ 2 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection. This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/video_sm/models/endomamba.py:35
↓ 2 callersMethod__init__
Simple block wrapping a mixer class with LayerNorm/RMSNorm and residual connection. This Block has a slightly different structure co
foundation_models/EndoMamba/videomamba/video_sm/models/endomamba_pretrain.py:35
↓ 2 callersMethod__init__
( self, dataset, num_replicas: Optional[int] = None, rank: Optional[int] = Non
src/datasets/utils/weighted_sampler.py:29
↓ 2 callersMethod__init__
Write header to internal buffers.
src/datasets/utils/dataloader.py:43
↓ 2 callersMethod__init__
(self)
evals/tecno_vid_jepa_torch_hub.py:281
↓ 2 callersMethod_aug_frame
( self, buffer, args, )
foundation_models/EndoMamba/videomamba/video_sm/datasets/kinetics.py:177
↓ 2 callersMethod_aug_frame
( self, buffer, args, )
foundation_models/EndoMamba/videomamba/video_sm/datasets/ssv2.py:195
← previousnext →101–200 of 2,319, ranked by callers