MCPcopy Create free account

hub / github.com/Haochen-Wang409/HPM / functions

Functions186 in github.com/Haochen-Wang409/HPM

↓ 104 callersFunctionprint
(*args, **kwargs)
util/misc.py:175
↓ 14 callersMethodload_state_dict
(self, state_dict)
util/misc.py:275
↓ 12 callersMethodstate_dict
(self)
util/misc.py:272
↓ 11 callersMethodupdate
(self, **kwargs)
util/misc.py:90
↓ 7 callersFunctionprint
(*args, **kwargs)
util/utils.py:174
↓ 6 callersMethod__init__
(self, embed_dim: int, # vision image_resolution: int,
models_clip.py:251
↓ 6 callersFunctionget_2d_sincos_pos_embed
grid_size: int of the grid height and width return: pos_embed: [grid_size*grid_size, embed_dim] or [1+grid_size*grid_size, embed_dim] (w/
util/pos_embed.py:17
↓ 5 callersMethodload_state_dict
(self, state_dict)
util/utils.py:294
↓ 4 callersMethod_make_layer
(self, planes, blocks, stride=1)
models_clip.py:136
↓ 4 callersFunctionbuild_dataset
(is_train, args)
util/datasets.py:47
↓ 4 callersFunctionevaluate
(data_loader, model, device)
engine_finetune.py:102
↓ 4 callersMethodlog_every
(self, iterable, print_freq, header=None)
util/misc.py:122
↓ 3 callersFunctioninterpolate_pos_embed
(model, checkpoint_model)
util/pos_embed.py:72
↓ 3 callersFunctionis_dist_avail_and_initialized
()
util/misc.py:186
↓ 3 callersFunctionis_dist_avail_and_initialized
()
util/utils.py:185
↓ 3 callersMethodstate_dict
(self)
util/utils.py:291
↓ 3 callersMethodsynchronize_between_processes
(self)
util/misc.py:115
↓ 2 callersMethodadd_meter
(self, name, meter)
util/misc.py:119
↓ 2 callersFunctionbuild_model
(state_dict: dict)
models_clip.py:406
↓ 2 callersFunctionextract_features
(model, data_loader, use_cuda=True)
main_knn.py:105
↓ 2 callersMethodforward_decoder
(self, x, mask)
models_mae_learn_feature_loss.py:190
↓ 2 callersMethodforward_features
(self, x, mask=None)
models_vit.py:33
↓ 2 callersMethodforward_loss
imgs: [N, 3, H, W] pred: [N, mask, p*p*3] mask: [N, L], 0 is keep, 1 is remove,
models_mae.py:198
↓ 2 callersFunctionget_1d_sincos_pos_embed_from_grid
embed_dim: output dimension for each position pos: a list of positions to be encoded: size (M,) out: (M, D)
util/pos_embed.py:46
↓ 2 callersFunctionget_world_size
()
util/misc.py:194
↓ 2 callersFunctionnorm_cdf
(x)
util/utils.py:366
↓ 2 callersFunctionsetup_for_distributed
This function disables printing when not in master process
util/misc.py:169
↓ 2 callersFunctionsetup_for_distributed
This function disables printing when not in master process
util/utils.py:168
↓ 2 callersMethodstep
(self)
util/lars.py:20
↓ 2 callersFunctiontrain_one_epoch
(model: torch.nn.Module, criterion: torch.nn.Module, data_loader: Iterable, optimizer: tor
engine_finetune.py:24
↓ 2 callersFunctiontrunc_normal_
(tensor, mean=0., std=1., a=-2., b=2.)
util/utils.py:396
↓ 2 callersMethodupdate
(self, value, n=1)
util/misc.py:36
↓ 2 callersMethodupdate
(self, value, n=1)
util/utils.py:35
↓ 1 callersFunction_no_grad_trunc_normal_
(tensor, mean, std, a, b)
util/utils.py:364
↓ 1 callersMethodattention
(self, x: torch.Tensor)
models_clip.py:192
↓ 1 callersMethodbuild_attention_mask
(self)
models_clip.py:335
↓ 1 callersFunctionbuild_transform
(is_train, args)
util/datasets.py:60
↓ 1 callersFunctionconvert_weights
Convert applicable model parameters to fp16
models_clip.py:382
↓ 1 callersMethodencode_image
(self, image)
models_clip.py:347
↓ 1 callersMethodencode_text
(self, text)
models_clip.py:350
↓ 1 callersMethodforward
(self, image, text)
models_clip.py:365
↓ 1 callersMethodforward_decoder
(self, x, mask)
models_mae.py:169
↓ 1 callersMethodforward_decoder
(self, x, mask)
models_mae_learn_loss.py:191
↓ 1 callersMethodforward_encoder
(self, x, mask)
models_mae.py:131
↓ 1 callersMethodforward_encoder
(self, x, mask)
models_mae_learn_loss.py:154
↓ 1 callersMethodforward_encoder
(self, x, mask)
models_mae_learn_feature_loss.py:153
↓ 1 callersFunctionforward_features
(model, x, model_type)
engine_pretrain.py:163
↓ 1 callersFunctionforward_features_clip
(model, x)
engine_pretrain.py:187
↓ 1 callersFunctionforward_features_dino
(model, x)
engine_pretrain.py:171
↓ 1 callersMethodforward_learning_loss
loss_pred: [N, L, 1] mask: [N, L], 0 is keep, 1 is remove, loss_target: [N, L]
models_mae_learn_loss.py:298
↓ 1 callersMethodgenerate_mask
(self, loss_pred, mask_ratio=0.75, images=None, guide=True, epoch=0, total_epoch=200)
models_mae_learn_loss.py:259
↓ 1 callersFunctionget_2d_sincos_pos_embed_from_grid
(embed_dim, grid)
util/pos_embed.py:35
↓ 1 callersFunctionget_args_parser
()
main_finetune.py:42
↓ 1 callersFunctionget_args_parser
()
main_knn.py:28
↓ 1 callersFunctionget_args_parser
()
main_pretrain.py:43
↓ 1 callersFunctionget_args_parser
()
main_linprob.py:39
↓ 1 callersFunctionget_grad_norm_
(parameters, norm_type: float = 2.0)
util/misc.py:279
↓ 1 callersFunctionget_grad_norm_
(parameters, norm_type: float = 2.0)
util/utils.py:298
↓ 1 callersFunctionget_layer_id_for_vit
Assign a parameter with its layer id Following BEiT: https://github.com/microsoft/unilm/blob/master/beit/optim_factory.py#L33
util/lr_decay.py:63
↓ 1 callersFunctionget_rank
()
util/misc.py:200
↓ 1 callersFunctionget_rank
()
util/utils.py:199
↓ 1 callersFunctionget_world_size
()
util/utils.py:193
↓ 1 callersMethodinitialize_parameters
(self)
models_clip.py:306
↓ 1 callersMethodinitialize_weights
(self)
models_mae.py:70
↓ 1 callersMethodinitialize_weights
(self)
models_mae_learn_loss.py:91
↓ 1 callersMethodinitialize_weights
(self)
models_mae_learn_feature_loss.py:90
↓ 1 callersFunctionis_main_process
()
util/misc.py:206
↓ 1 callersFunctionis_main_process
()
util/utils.py:205
↓ 1 callersFunctionknn_classifier
(train_features, train_labels, test_features, test_labels, k, T, num_classes=1000)
main_knn.py:154
↓ 1 callersFunctionmain
(args)
main_finetune.py:158
↓ 1 callersFunctionmain
(args)
main_knn.py:201
↓ 1 callersFunctionmain
(args)
main_pretrain.py:131
↓ 1 callersFunctionmain
(args)
main_linprob.py:111
↓ 1 callersMethodmax
(self)
util/misc.py:69
↓ 1 callersMethodmax
(self)
util/utils.py:68
↓ 1 callersMethodpatchify
imgs: (N, 3, H, W) x: (N, L, patch_size**2 *3)
models_mae.py:102
↓ 1 callersMethodpatchify
imgs: (N, 3, H, W) x: (N, L, patch_size**2 *3)
models_mae_learn_loss.py:125
↓ 1 callersFunctionsave_on_master
(*args, **kwargs)
util/misc.py:210
↓ 1 callersFunctionsave_on_master
(*args, **kwargs)
util/utils.py:209
↓ 1 callersFunctiontrain_one_epoch
(model: torch.nn.Module, data_loader: Iterable, optimizer: torch.optim.Optimizer,
engine_pretrain.py:22
↓ 1 callersMethodupdate
(self, **kwargs)
util/utils.py:89
Method__call__
(self)
mask_transform.py:53
Method__call__
(self, image)
mask_transform.py:116
Method__call__
(self, loss, optimizer, clip_grad=5., parameters=None, create_graph=False, update_grad=True, retain_graph=Fals
util/misc.py:256
Method__call__
(self, loss, optimizer, clip_grad=None, parameters=None, create_graph=False, update_grad=True)
util/utils.py:274
Method__getattr__
(self, attr)
util/misc.py:99
Method__getattr__
(self, attr)
util/utils.py:98
Method__init__
(self, input_size, mask_ratio, regular=False, block=False)
mask_transform.py:18
Method__init__
(self, args, is_train=True)
mask_transform.py:84
Method__init__
(self, global_pool=False, **kwargs)
models_vit.py:22
Method__init__
(self, inplanes, planes, stride=1)
models_clip.py:20
Method__init__
(self, spacial_dim: int, embed_dim: int, num_heads: int, output_dim: int = None)
models_clip.py:66
Method__init__
(self, layers, output_dim, heads, input_resolution=224, width=64)
models_clip.py:109
Method__init__
(self, d_model: int, n_head: int, attn_mask: torch.Tensor = None)
models_clip.py:179
Method__init__
(self, width: int, layers: int, heads: int, attn_mask: torch.Tensor = None)
models_clip.py:203
Method__init__
(self, input_resolution: int, patch_size: int, width: int, layers: int, heads: int, output_dim: int)
models_clip.py:214
Method__init__
(self, img_size=224, patch_size=16, in_chans=3, embed_dim=1024, depth=24, num_heads=16,
models_mae.py:24
Method__init__
(self, img_size=224, patch_size=16, in_chans=3, embed_dim=1024, depth=24, num_heads=16,
models_mae_learn_loss.py:28
Method__init__
(self, img_size=224, patch_size=16, in_chans=3, embed_dim=1024, depth=24, num_heads=16,
models_mae_learn_feature_loss.py:28
Method__init__
(self, params, lr=0, weight_decay=0, momentum=0.9, trust_coefficient=0.001)
util/lars.py:15
next →1–100 of 186, ranked by callers