Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/OpenGVLab/UniFormerV2
/ functions
Functions
872 in github.com/OpenGVLab/UniFormerV2
⨍
Functions
872
◇
Types & classes
124
↓ 1 callers
Method
get_output_file
Return a video writer object. Args: path (str): path to the output video file. fps (int or float): frames per
slowfast/visualization/demo_loader.py:211
↓ 1 callers
Method
get_output_file
Return a video writer object. Args: path (str): path to the output video file.
slowfast/visualization/ava_demo_precomputed_boxes.py:77
↓ 1 callers
Method
get_params
Get parameters for ``crop`` for a random sized crop. Args: img (PIL Image): Image to be cropped. scale (tuple): range
slowfast/datasets/transform.py:763
↓ 1 callers
Function
get_path_to_checkpoint
Get the full path to a checkpoint file. Args: path_to_job (string): the path to the folder of the current job. step (int): th
slowfast/utils/checkpoint_amp_co.py:46
↓ 1 callers
Function
get_path_to_checkpoint
Get the full path to a checkpoint file. Args: path_to_job (string): the path to the folder of the current job. epoch (int): t
slowfast/utils/checkpoint.py:47
↓ 1 callers
Function
get_path_to_checkpoint
Get the full path to a checkpoint file. Args: path_to_job (string): the path to the folder of the current job. epoch (int): t
slowfast/utils/checkpoint_amp_ema.py:49
↓ 1 callers
Function
get_path_to_checkpoint
Get the full path to a checkpoint file. Args: path_to_job (string): the path to the folder of the current job. epoch (int): t
slowfast/utils/checkpoint_amp.py:46
↓ 1 callers
Method
get_predictions
Predict and append prediction results to each box in each keyframe in `self.pred_boxes` dictionary.
slowfast/visualization/ava_demo_precomputed_boxes.py:124
↓ 1 callers
Method
get_pretrained_model
(self, cfg)
slowfast/models/uniformer.py:396
↓ 1 callers
Function
get_rank
Get the rank of the current process.
slowfast/utils/distributed.py:127
↓ 1 callers
Method
get_seq_frames
Given the video index, return the list of indexs of sampled frames. Args: index (int): the video index. Returns:
slowfast/datasets/charades.py:113
↓ 1 callers
Function
get_sequence
Sample frames among the corresponding clip. Args: center_idx (int): center frame idx for current clip half_len (int): half o
slowfast/datasets/utils.py:50
↓ 1 callers
Function
get_stem_func
Retrieves the stem module by name.
slowfast/models/stem_helper.py:9
↓ 1 callers
Function
get_step_index
Retrieves the lr step index for the given epoch. Args: cfg (CfgNode): configs. Details can be found in slowfast/config/de
slowfast/utils/lr_policy.py:69
↓ 1 callers
Function
get_trans_func
Retrieves the transformation module by name.
slowfast/models/resnet_helper.py:14
↓ 1 callers
Method
get_weights
Returns weights from registered layers. Returns: weights (Python dictionary): a dictionary of the pair {layer
slowfast/visualization/utils.py:236
↓ 1 callers
Function
get_world_size
Get the size of the world.
slowfast/utils/distributed.py:116
↓ 1 callers
Function
gpu_mem_usage
Compute the GPU memory usage for the current device (GB).
slowfast/utils/misc.py:53
↓ 1 callers
Function
inflate_weight
Inflate 2D model weights in state_dict_2d to the 3D model weights in state_dict_3d. The details can be found in: Joao Carreira, and Andre
slowfast/utils/checkpoint_amp_co.py:200
↓ 1 callers
Function
inflate_weight
Inflate 2D model weights in state_dict_2d to the 3D model weights in state_dict_3d. The details can be found in: Joao Carreira, and Andre
slowfast/utils/checkpoint.py:152
↓ 1 callers
Function
inflate_weight
Inflate 2D model weights in state_dict_2d to the 3D model weights in state_dict_3d. The details can be found in: Joao Carreira, and Andre
slowfast/utils/checkpoint_amp_ema.py:199
↓ 1 callers
Function
inflate_weight
Inflate 2D model weights in state_dict_2d to the 3D model weights in state_dict_3d. The details can be found in: Joao Carreira, and Andre
slowfast/utils/checkpoint_amp.py:196
↓ 1 callers
Function
inflate_weight
(weight_2d, time_dim, center=True)
slowfast/models/uniformerv2_model.py:333
↓ 1 callers
Method
inflate_weight
(self, weight_2d, time_dim, center=False)
slowfast/models/uniformer.py:385
↓ 1 callers
Method
init_multigrid
Update cfg based on multigrid settings. Args: cfg (configs): configs that contains training and multigrid specific
slowfast/utils/multigrid.py:18
↓ 1 callers
Method
initialize_parameters
(self)
extract_clip/model.py:299
↓ 1 callers
Function
ioa
Computes pairwise intersection-over-area between box and mask collections. Intersection-over-area (ioa) between two masks mask1 and mask2 is defi
slowfast/utils/ava_evaluation/np_box_mask_list_ops.py:99
↓ 1 callers
Function
ioa
Computes pairwise intersection-over-area between box collections. Intersection-over-area (ioa) between two boxes box1 and box2 is defined as
slowfast/utils/ava_evaluation/np_box_list_ops.py:84
↓ 1 callers
Function
load_boxes_labels
Loading boxes and labels from AVA bounding boxes csv files. Args: cfg (CfgNode): config. video_name (str): name of the given
slowfast/visualization/ava_demo_precomputed_boxes.py:390
↓ 1 callers
Method
load_image
Prepares the image for network input with format of CHW RGB float
slowfast/datasets/imagenet.py:82
↓ 1 callers
Function
main
()
tools/benchmark.py:15
↓ 1 callers
Function
main
Main function to spawn the train and test process.
tools/run_net.py:15
↓ 1 callers
Function
main
Main function to spawn the train and test process.
tools/run_net_multi_node.py:25
↓ 1 callers
Method
median_epoch_time
Calculate the median epoch time among the recorded epochs.
slowfast/utils/meters.py:827
↓ 1 callers
Function
mixup_target
This function converts target class indices to one-hot vectors, given the number of classes. Args: targets (loader): Class labels
slowfast/datasets/mixup.py:40
↓ 1 callers
Function
non_max_suppression
Non maximum suppression. This op greedily selects a subset of detection bounding boxes, pruning away boxes that have high IOU (intersection o
slowfast/utils/ava_evaluation/np_box_mask_list_ops.py:174
↓ 1 callers
Function
non_max_suppression
Non maximum suppression. This op greedily selects a subset of detection bounding boxes, pruning away boxes that have high IOU (intersection o
slowfast/utils/ava_evaluation/np_box_list_ops.py:167
↓ 1 callers
Function
normal_to_sub_bn
Convert BN parameters to Sub-BN parameters if model contains Sub-BNs. Args: checkpoint_sd (OrderedDict): source dict of parameters.
slowfast/utils/checkpoint_amp_co.py:485
↓ 1 callers
Function
normal_to_sub_bn
Convert BN parameters to Sub-BN parameters if model contains Sub-BNs. Args: checkpoint_sd (OrderedDict): source dict of parameters.
slowfast/utils/checkpoint.py:434
↓ 1 callers
Function
normal_to_sub_bn
Convert BN parameters to Sub-BN parameters if model contains Sub-BNs. Args: checkpoint_sd (OrderedDict): source dict of parameters.
slowfast/utils/checkpoint_amp_ema.py:472
↓ 1 callers
Function
normal_to_sub_bn
Convert BN parameters to Sub-BN parameters if model contains Sub-BNs. Args: checkpoint_sd (OrderedDict): source dict of parameters.
slowfast/utils/checkpoint_amp.py:469
↓ 1 callers
Function
pad_image
Pad the given image with the size of pad_size. Args: image (array): image to pad. pad_size (int): size to pad. order
slowfast/datasets/cv2_transform.py:319
↓ 1 callers
Function
params_count
Compute the number of parameters. Args: model (model): model to count the number of parameters.
slowfast/utils/misc.py:36
↓ 1 callers
Function
parse_ip
(s)
tools/run_net_multi_node.py:17
↓ 1 callers
Function
perform_test
For classification: Perform mutli-view testing that uniformly samples N clips from a video along its temporal axis. For each clip, it tak
tools/test_net.py:25
↓ 1 callers
Function
plot_hist
Given all predictions and all true labels, plot histograms of top-k most frequently predicted classes for each true class. Args:
slowfast/visualization/tensorboard_vis.py:283
↓ 1 callers
Method
plot_weights_and_activations
Visualize weights/ activations tensors to Tensorboard. Args: weight_activation_dict (dict[str, tensor]): a dictionary of
slowfast/visualization/tensorboard_vis.py:186
↓ 1 callers
Function
print_schedule
Log schedule.
slowfast/utils/multigrid.py:215
↓ 1 callers
Method
print_summary
(self)
slowfast/datasets/ava_dataset.py:87
↓ 1 callers
Function
process_layer_index_data
Extract layer names and numpy-like fancy indexing from a string. Args: layer_ls (list of strs): list of strings containing data about
slowfast/visualization/utils.py:278
↓ 1 callers
Method
put
Add the new task to task queue. Args: task (TaskInfo object): task object that contain the necessary info
slowfast/visualization/async_predictor.py:78
↓ 1 callers
Function
pyav_decode
Convert the video from its original fps to the target_fps. If the video support selective decoding (contain decoding information in the video
slowfast/datasets/decoder.py:251
↓ 1 callers
Function
pyav_decode_stream
Decode the video with PyAV decoder. Args: container (container): PyAV container. start_pts (int): the starting Presentation T
slowfast/datasets/decoder.py:94
↓ 1 callers
Function
rand_augment_ops
(magnitude=10, hparams=None, transforms=None)
slowfast/datasets/rand_augment.py:455
↓ 1 callers
Function
rand_bbox
Generates a random square bbox based on lambda value. Args: img_shape (tuple): Image shape as tuple lam (float): Cutmix lamb
slowfast/datasets/mixup.py:67
↓ 1 callers
Method
reset
Reset the metric.
slowfast/utils/meters.py:287
↓ 1 callers
Method
reset
Reset the metric.
slowfast/utils/meters_co.py:287
↓ 1 callers
Function
run_visualization
Run model visualization (weights, activations and model inputs) and visualize them on Tensorboard. Args: vis_loader (loader): vid
tools/visualization.py:29
↓ 1 callers
Function
saturation
Perform color saturation on the given image. Args: var (float): variance. image (array): image to perform color saturation.
slowfast/datasets/cv2_transform.py:654
↓ 1 callers
Function
saturation_jitter
Perfrom saturation jittering on the input images. The channels of images should be in order BGR. Args: var (float): jitter ratio
slowfast/datasets/transform.py:424
↓ 1 callers
Function
saturation_list
Perform color saturation on the list of given images. Args: var (float): variance. images (list): list of images to perform c
slowfast/datasets/cv2_transform.py:697
↓ 1 callers
Function
scale
Scale box coordinates in x and y dimensions. Args: boxlist: BoxList holding N boxes y_scale: float x_scale: float Returns:
slowfast/utils/ava_evaluation/np_box_list_ops.py:321
↓ 1 callers
Function
scale_boxes
Scale the short side of the box to size. Args: size (int): size to scale the image. boxes (ndarray): bounding boxes to peform
slowfast/datasets/cv2_transform.py:106
↓ 1 callers
Function
sec_to_frame
Convert time index (in second) to frame index. 0: 900 30: 901
slowfast/datasets/ava_helper.py:130
↓ 1 callers
Function
sec_to_frameidx
(sec)
slowfast/visualization/ava_demo_precomputed_boxes.py:408
↓ 1 callers
Function
sort_by_field
Sort boxes and associated fields according to a scalar field. A common use case is reordering the boxes according to descending scores. Args
slowfast/utils/ava_evaluation/np_box_mask_list_ops.py:151
↓ 1 callers
Function
sub_to_normal_bn
Convert the Sub-BN paprameters to normal BN parameters in a state dict. There are two copies of BN layers in a Sub-BN implementation: `bn.bn`
slowfast/utils/checkpoint.py:373
↓ 1 callers
Function
temporal_sampling
Given the start and end frame index, sample num_samples frames between the start and end with equal interval. Args: frames (tenso
slowfast/datasets/decoder.py:11
↓ 1 callers
Function
tensor_normalize
Normalize a given tensor by subtracting the mean and dividing the std. Args: tensor (tensor): tensor to normalize. mean (tens
slowfast/datasets/utils.py:351
↓ 1 callers
Function
torchvision_decode
If video_meta is not empty, perform temporal selective decoding to sample a clip from the video with TorchVision decoder. If video_meta is em
slowfast/datasets/decoder.py:136
↓ 1 callers
Function
train_epoch
Perform the video training for one epoch. Args: train_loader (loader): video training loader. model (model): the video model
tools/train_net.py:29
↓ 1 callers
Function
transform
(x, y, matrix)
slowfast/datasets/rand_augment.py:128
↓ 1 callers
Function
transforms_imagenet_train
If separate==True, the transforms are returned as a tuple of 3 separate transforms for use in a mixing dataset that passes * all data th
slowfast/datasets/transform.py:835
↓ 1 callers
Function
uniformerv2_b16
( pretrained=True, use_checkpoint=False, checkpoint_num=[0], t_size=16, dw_reduction=1.5, backbone_dro
slowfast/models/uniformerv2_model.py:359
↓ 1 callers
Method
update_predictions
Update predictions and labels. Args: preds (tensor): model output predictions. labels (tensor): labels.
slowfast/utils/meters.py:678
↓ 1 callers
Function
whitespace_clean
(text)
extract_clip/simple_tokenizer.py:56
Function
CHW2HWC
Transpose the dimension from `channel` x `height` x `width` to `height` x `width` x `channel`. Args: image (array): image to
slowfast/datasets/cv2_transform.py:216
Function
HWC2CHW
Transpose the dimension from `height` x `width` x `channel` to `channel` x `height` x `width`. Args: image (array): image to
slowfast/datasets/cv2_transform.py:228
Function
Ptvcharades
Construct PyTorchVideo Charades video loader. Load Charades data (frame paths, labels, etc. ) to Charades Dataset object. The dataset cou
slowfast/datasets/ptv_datasets.py:311
Function
Ptvkinetics
Construct the Kinetics video loader with a given csv file. The format of the csv file is: ``` path_to_video_1 label_1 path_to_vid
slowfast/datasets/ptv_datasets.py:143
Function
Ptvssv2
Construct PyTorchVideo Something-Something v2 SSv2 video loader. Load SSv2 data (frame paths, labels, etc. ) to SSv2 Dataset object. The
slowfast/datasets/ptv_datasets.py:454
Method
__call__
(self, task)
slowfast/visualization/async_predictor.py:106
Method
__call__
How many results are ready to be returned.
slowfast/visualization/async_predictor.py:213
Method
__call__
Returns the prediction results for the current task. Args: task (TaskInfo object): task object that contain
slowfast/visualization/predictor.py:50
Method
__call__
Visualize the localization maps on their corresponding inputs as heatmap, using Grad-CAM. Args: inputs (list of t
slowfast/visualization/gradcam_utils.py:149
Method
__call__
(self)
slowfast/visualization/ava_demo_precomputed_boxes.py:313
Method
__call__
Args: img (PIL Image): Image to be cropped and resized. Returns: PIL Image: Randomly cropped and resized imag
slowfast/datasets/transform.py:803
Method
__call__
(self, x, target)
slowfast/datasets/mixup.py:183
Method
__call__
(self, img_list)
slowfast/datasets/rand_augment.py:366
Method
__call__
(self, img)
slowfast/datasets/rand_augment.py:470
Method
__call__
(self, input)
slowfast/datasets/random_erasing.py:158
Method
__getitem__
Given the video index, return the list of frames, label, and video index if the video can be fetched and decoded successfully, otherw
slowfast/datasets/kinetics.py:131
Method
__getitem__
Given the video index, return the list of frames, label, and video index if the video can be fetched and decoded successfully, otherw
slowfast/datasets/mit.py:130
Method
__getitem__
Generate corresponding clips, boxes, labels and metadata for given idx. Args: idx (int): the video index provided by the
slowfast/datasets/ava_dataset.py:352
Method
__getitem__
(self, index)
slowfast/datasets/imagenet.py:189
Method
__getitem__
Given the video index, return the list of frames, label, and video index if the video can be fetched and decoded successfully, otherw
slowfast/datasets/kinetics_sparse.py:131
Method
__getitem__
Given the video index, return the list of frames, label, and video index if the video can be fetched and decoded successfully, otherw
slowfast/datasets/anet.py:136
Method
__getitem__
Given the video index, return the list of frames, label, and video index if the video frames can be fetched. Args:
slowfast/datasets/charades.py:154
Method
__getitem__
Given the video index, return the list of frames, label, and video index if the video frames can be fetched. Args:
slowfast/datasets/sth.py:162
Method
__init__
(self, bpe_path: str = default_bpe())
extract_clip/simple_tokenizer.py:63
← previous
next →
301–400 of 872, ranked by callers