MCPcopy Create free account

hub / github.com/Chain123/Meta-HAR / functions

Functions81 in github.com/Chain123/Meta-HAR

↓ 8 callersMethodtrain
(self, num_epoch)
met-har.py:93
↓ 5 callersMethodget_model_weights
(self)
reptile.py:85
↓ 5 callersMethodget_model_weights
(self)
met-har.py:87
↓ 4 callersMethodassign_new_weights
(self, weights_dict)
reptile.py:88
↓ 4 callersMethodassign_new_weights
(self, weights_dict)
met-har.py:90
↓ 4 callersMethodtest
(self, print_ind=False)
reptile.py:127
↓ 4 callersMethodtrain
(self, num_epoch, global_center=None)
reptile.py:91
↓ 3 callersMethod__init__
(self)
utils.py:75
↓ 3 callersMethod__init__
(self, sensor_block, seq_len, batch_size, logits_len=None, embed=False, embed_len=100, rnn_layer=2,
har_model.py:68
↓ 2 callersMethodadapt_merged_2
First Adapt embedding net, then fine-tune the last layer.
met-har.py:283
↓ 2 callersMethodbuild_data_loader
(self)
reptile.py:71
↓ 2 callersMethodbuild_data_loader
(self)
met-har.py:68
↓ 2 callersFunctiondata_process_sensor
(data_str, length=150)
data_process/feature_extraction.py:110
↓ 2 callersFunctionload_pickle
(filename, show_name=False)
reptile.py:32
↓ 2 callersFunctionsave_pickle
(data_dict, filename)
data_process/feature_extraction.py:24
↓ 2 callersMethodset_train_test_file
(self, train, test, adapt)
reptile.py:80
↓ 2 callersMethodset_train_test_file
(self, train, test, adapt)
met-har.py:81
↓ 2 callersMethodtest
(self, print_ind=False)
met-har.py:139
↓ 2 callersMethodtrain_step
(self, epochs)
Central.py:55
↓ 1 callersMethod__init__
(self, modelA, modelB)
met-har.py:22
↓ 1 callersFunctionaction_encoding
(act, one_hot=False)
data_process/feature_extraction.py:100
↓ 1 callersMethodadapt
Used for test only
reptile.py:151
↓ 1 callersMethodadapt_train
(self)
reptile.py:179
↓ 1 callersFunctionall_central
()
Central.py:123
↓ 1 callersFunctionaxisData_split
split sensor data into small interval, for LSTM unit training sensor_data: numpy.array with shape [seq_len, 8] interval_len: int, the len
data_process/feature_extraction.py:29
↓ 1 callersFunctiondim_expansion
add the fourth dim for the original :param data: numpy.array ax, ay, az, mx, my, mz data with shape [interval_len, 6] :return: numpy.arra
data_process/feature_extraction.py:47
↓ 1 callersFunctionfeature_extract
Args: in_dir: folder where the original txt data stores (format of the txt file can be found in readme) out_dir: output .pickle f
data_process/feature_extraction.py:125
↓ 1 callersFunctionfeature_extraction_dict
Feature extraction for each data sample, FFT, frequency and magnitude
data_process/feature_extraction.py:67
↓ 1 callersFunctionmain
:param rounds: global rounds for federated learning: type: float :param in_dir: input data dir: type: string :param out_dir: output re
reptile.py:280
↓ 1 callersFunctionmain
:param rounds: global rounds for federated learning: type: float :param out_dir: output result dir: type: string :param lr: initial le
met-har.py:403
↓ 1 callersFunctionmain
(in_dir, out_dir)
data_process/feature_extraction.py:185
↓ 1 callersFunctionupdate_server_weights
model_1 and model_2 with same structure return weights dictionary with values w_model_1 - w_model_2 sigma = 1 : federated learning
reptile.py:205
↓ 1 callersFunctionupdate_server_weights
model 1 and model 2 with same structure return weights dict with values w_model1 - w_model2 sigma = 1 : federated learning
met-har.py:330
↓ 1 callersMethodvalid
(self)
Central.py:33
Method__getitem__
(self, index)
data_loader.py:38
Method__getitem__
Args: index (int): Index Returns: tuple: (image, target, target_t) target is index of the g
data_loader.py:69
Method__init__
(self)
utils.py:96
Method__init__
(self)
utils.py:127
Method__init__
(self)
utils.py:151
Method__init__
(self, in_planes, planes)
har_model.py:10
Method__init__
(self, in_planes, planes)
har_model.py:31
Method__init__
(self, embed_len, number_class)
har_model.py:97
Method__init__
graph can be norm_cce, merge_cce
reptile.py:45
Method__init__
Args: filename: a list of pickle files. transform: transform applied to the feature data.
data_loader.py:12
Method__init__
(self, filename, transform=None, target_transform=None, target="hot")
data_loader.py:51
Method__init__
graph can be norm_embed
met-har.py:35
Method__init__
(self, trainloader, testloader)
Central.py:25
Method__len__
(self)
data_loader.py:46
Method__len__
(self)
data_loader.py:87
Methodadapt
First Adapt embedding net, then fine-tune the last layer.
met-har.py:166
Methodadapt_fixed
First Adapt embedding net, then fine-tune the last layer.
met-har.py:213
Methodadapt_merged
First Adapt embedding net, then fine-tune the last layer.
met-har.py:252
Methodasign_merge_model
(self)
met-har.py:249
Functiondataloader_gen
Args: filename: a list of pickle files that stores the processed HAR data (after FFT) batch_size: batch size
utils.py:43
Functiondataloader_gen2
(filename, batch_size, train=True, target="logits")
utils.py:57
Methodforward
(self, embed, target, chunck_size, Expand=10)
utils.py:78
Methodforward
(self, embed, target, chunk_size, global_center=None, beta=2.0, Expand=10)
utils.py:99
Methodforward
(self, output, target, embed, chuck_size, global_center=None, beta=0.25, Expand=10)
utils.py:130
Methodforward
(self, output, target, embed, chunck_size, global_center=None, beta=0.25, Expand=10)
utils.py:154
Methodforward
(self, x)
har_model.py:22
Methodforward
input x with shape b, c = 1, seq_len, sensor_dim = 16, interval_len = (7 /12 ?)
har_model.py:50
Methodforward
x with shape [batch, channel, seq_len, H, W]
har_model.py:84
Methodforward
(self, x)
har_model.py:102
Methodforward
(self, x)
met-har.py:27
Methodlabel_transfer
(self, target)
met-har.py:53
Functionload_pickle
(filename)
utils.py:64
Functionload_pickle
(filename, show_name=False)
Central.py:96
Functionload_pickle
(filename, show_name=False)
data_process/feature_extraction.py:18
Functionmerge_cce
(bidirectional, num_classes=6)
har_model.py:112
Functionmerge_embed
(bidirectional)
har_model.py:106
Functionnorm_cce
(bidirectional, num_classes=6)
har_model.py:124
Functionnorm_embed
(bidirectional)
har_model.py:118
Methodsave_model
filename example: /path/checkpoint/model-100.t7 State dict contains: "model" key at least.
reptile.py:61
Methodsave_model
filename example: /path/checkpoint/model-100.t7 State dict contains: "model" key at least.
met-har.py:58
Functionsave_pickle
(dict_name, file_name)
utils.py:69
Functionsave_pickle
(data_dict, filename)
reptile.py:38
Functionsave_pickle
(data_dict, filename)
Central.py:91
Functionself_test_all
(in_dir)
Central.py:102
Methodtest_2
(self, print_ind=False)
met-har.py:114
Functionupdate_server_weights_weighted
abandon: more complicated way to update the model on the server side.
reptile.py:220
Functionupdate_server_weights_weighted
(w_list, w, sigma=0.2)
met-har.py:345