Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/AberHu/Knowledge-Distillation-Zoo
/ functions
Functions
124 in github.com/AberHu/Knowledge-Distillation-Zoo
⨍
Functions
124
◇
Types & classes
33
↓ 74 callers
Method
update
(self, val, n=1)
utils.py:20
↓ 16 callers
Method
normalize
(self, factor)
kd_losses/ft.py:22
↓ 15 callers
Function
accuracy
Computes the precision@k for the specified values of k
utils.py:61
↓ 13 callers
Function
count_parameters_in_MB
(model)
utils.py:27
↓ 11 callers
Function
define_tsnet
(name, num_class, cuda=True)
network.py:8
↓ 10 callers
Method
get_channel_num
(self)
network.py:113
↓ 10 callers
Function
load_pretrained_model
(model, pretrained_dict)
utils.py:37
↓ 6 callers
Function
create_exp_dir
(path)
utils.py:31
↓ 6 callers
Function
save_checkpoint
(state, is_best, save_root)
utils.py:53
↓ 4 callers
Method
__init__
(self, in_channels, out_channels, return_before_act)
network.py:25
↓ 4 callers
Method
euclidean_dist_fm
Calculating the IRG edge of feature map.
kd_losses/irg.py:76
↓ 3 callers
Method
__init__
(self, s_dim, t_dim, feat_dim, nce_n, nce_t, nce_mom, n_data)
kd_losses/crd.py:31
↓ 3 callers
Function
conv1x1
(in_channels, out_channels)
kd_losses/vid.py:10
↓ 3 callers
Method
make_layer
(self, block, num, in_channels, out_channels)
network.py:90
↓ 3 callers
Method
make_layer
(self, block, num, in_channels, out_channels)
network.py:150
↓ 3 callers
Method
poly_kernel
(self, fm1, fm2)
kd_losses/nst.py:59
↓ 2 callers
Method
attention_map
(self, fm, eps=1e-6)
kd_losses/at.py:27
↓ 2 callers
Method
euclidean_dist_feat
Calculating the IRG edge of feat.
kd_losses/irg.py:94
↓ 2 callers
Method
euclidean_dist_fms
Calculating the IRG Transformation, where fm1 precedes fm2 in the network.
kd_losses/irg.py:56
↓ 2 callers
Method
fsp_matrix
(self, fm1, fm2)
kd_losses/fsp.py:22
↓ 2 callers
Method
get_correlation_matrix
(self, feat)
kd_losses/cc.py:32
↓ 2 callers
Method
pdist
(self, feat, squared=False, eps=1e-12)
kd_losses/rkd.py:56
↓ 1 callers
Method
__init__
(self, root, train=True, transform=None, target_transform=None, download=False, n=4096, mode='exact
dataset.py:14
↓ 1 callers
Function
adjust_lr
(optimizer, epoch)
train_crd.py:296
↓ 1 callers
Function
adjust_lr
(optimizers, epoch)
train_dml.py:332
↓ 1 callers
Function
adjust_lr
(optimizer, epoch)
train_bss.py:319
↓ 1 callers
Function
adjust_lr
(optimizer, epoch)
train_base.py:241
↓ 1 callers
Function
adjust_lr
(optimizer, epoch)
train_ft.py:361
↓ 1 callers
Function
adjust_lr
(optimizer, epoch)
train_kd.py:543
↓ 1 callers
Function
adjust_lr_init
(optimizer, epoch)
train_kd.py:531
↓ 1 callers
Method
attack
(self, model, img, target, attack_class)
kd_losses/bss.py:46
↓ 1 callers
Function
define_paraphraser
(in_channels_t, k, use_bn, cuda=True)
network.py:185
↓ 1 callers
Function
define_translator
(in_channels_s, in_channels_t, k, use_bn=True, cuda=True)
network.py:237
↓ 1 callers
Method
get_margin
(self, fm, eps=1e-6)
kd_losses/ofd.py:45
↓ 1 callers
Function
l2_norm
(x, keepdim=True)
kd_losses/bss.py:18
↓ 1 callers
Function
main
()
train_crd.py:75
↓ 1 callers
Function
main
()
train_dml.py:67
↓ 1 callers
Function
main
()
train_bss.py:69
↓ 1 callers
Function
main
()
train_base.py:60
↓ 1 callers
Function
main
()
train_ft.py:69
↓ 1 callers
Function
main
()
train_kd.py:84
↓ 1 callers
Function
reduce_sum
(x, keepdim=True)
kd_losses/bss.py:12
↓ 1 callers
Method
reset
(self)
utils.py:14
↓ 1 callers
Method
rkd_angle
(self, feat_s, feat_t)
kd_losses/rkd.py:42
↓ 1 callers
Method
rkd_dist
(self, feat_s, feat_t)
kd_losses/rkd.py:29
↓ 1 callers
Function
test
(test_loader, nets, criterions, epoch)
train_crd.py:263
↓ 1 callers
Function
test
(test_loader, nets, criterions)
train_dml.py:275
↓ 1 callers
Function
test
(test_loader, nets, criterions, epoch)
train_bss.py:286
↓ 1 callers
Function
test
(test_loader, net, criterion)
train_base.py:213
↓ 1 callers
Function
test
(test_loader, nets, criterions)
train_ft.py:317
↓ 1 callers
Function
test
(test_loader, nets, criterions, epoch)
train_kd.py:447
↓ 1 callers
Function
train
(train_loader, nets, optimizer, criterions, epoch)
train_crd.py:202
↓ 1 callers
Function
train
(train_loader, nets, optimizers, criterions, epoch)
train_dml.py:188
↓ 1 callers
Function
train
(train_loader, nets, optimizer, criterions, attacker, epoch)
train_bss.py:188
↓ 1 callers
Function
train
(train_loader, net, optimizer, criterion, epoch)
train_base.py:169
↓ 1 callers
Function
train
(train_loader, nets, optimizer, criterions, epoch)
train_ft.py:255
↓ 1 callers
Function
train
(train_loader, nets, optimizer, criterions, epoch)
train_kd.py:347
↓ 1 callers
Function
train_init
(train_loader, nets, optimizer, criterions, total_epoch)
train_kd.py:274
↓ 1 callers
Function
train_para
(train_loader, nets, optimizer_para, criterionPara, total_epoch)
train_ft.py:210
Method
__getitem__
(self, index)
dataset.py:48
Method
__getitem__
(self, index)
dataset.py:106
Method
__init__
(self, num_class)
network.py:66
Method
__init__
(self, num_class)
network.py:126
Method
__init__
(self, in_channels_t, k, use_bn=True)
network.py:196
Method
__init__
(self, in_channels_s, in_channels_t, k, use_bn=True)
network.py:248
Method
__init__
(self)
utils.py:11
Method
__init__
(self, root, train=True, transform=None, target_transform=None, download=False, n=4096, mode='exact
dataset.py:72
Method
__init__
(self)
kd_losses/fitnet.py:14
Method
__init__
(self, in_dim, out_dim)
kd_losses/crd.py:51
Method
__init__
(self, n_data, eps=1e-7)
kd_losses/crd.py:67
Method
__init__
(self, feat_dim, n_data, nce_n, nce_t, nce_mom)
kd_losses/crd.py:91
Method
__init__
(self, in_channels, att_f)
kd_losses/afd.py:22
Method
__init__
(self, in_channels, mid_channels, out_channels, init_var, eps=1e-6)
kd_losses/vid.py:23
Method
__init__
(self)
kd_losses/sobolev.py:18
Method
__init__
(self)
kd_losses/lwm.py:20
Method
__init__
(self, w_dist, w_angle)
kd_losses/rkd.py:17
Method
__init__
(self)
kd_losses/dml.py:17
Method
__init__
(self, w_irg_vert, w_irg_edge, w_irg_tran)
kd_losses/irg.py:18
Method
__init__
(self)
kd_losses/pkt.py:17
Method
__init__
(self)
kd_losses/ft.py:14
Method
__init__
(self, T)
kd_losses/st.py:14
Method
__init__
(self)
kd_losses/fsp.py:14
Method
__init__
(self, in_channels, out_channels)
kd_losses/ofd.py:19
Method
__init__
(self, T)
kd_losses/bss.py:28
Method
__init__
(self, step_alpha, num_steps, eps=1e-4)
kd_losses/bss.py:41
Method
__init__
(self, margin)
kd_losses/ab.py:14
Method
__init__
(self)
kd_losses/nst.py:43
Method
__init__
(self)
kd_losses/logits.py:14
Method
__init__
(self, gamma, P_order)
kd_losses/cc.py:19
Method
__init__
(self, p)
kd_losses/at.py:18
Method
__init__
(self)
kd_losses/sp.py:14
Method
forward
(self, x)
network.py:43
Method
forward
(self, x)
network.py:97
Method
forward
(self, x)
network.py:157
Method
forward
(self, x)
network.py:231
Method
forward
(self, x)
network.py:272
Method
forward
(self, fm_s, fm_t)
kd_losses/fitnet.py:17
Method
forward
(self, feat_s, feat_t, idx, sample_idx)
kd_losses/crd.py:39
Method
forward
(self, x)
kd_losses/crd.py:55
Method
forward
(self, x)
kd_losses/crd.py:72
next →
1–100 of 124, ranked by callers