-
Notifications
You must be signed in to change notification settings - Fork 15
/
main_mogonet_zly.py
57 lines (53 loc) · 1.66 KB
/
main_mogonet_zly.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
""" Example for MOGONET classification
"""
from train_test import train_test
# #simulations
if __name__ == "__main__":
datatypes=["equal","heterogeneous"]
datatypes=["heterogeneous"]
typenums=[5,10,15]
typenums=[15]
for datatype in datatypes:
for typenum in typenums:
datapath='simulations/{}/{}'.format(datatype, typenum)
data_folder = datapath
view_list = [1,2,3]
num_epoch_pretrain = 1000
num_epoch = 2500
lr_e_pretrain = 1e-3
lr_e = 5e-4
lr_c = 1e-3
# if data_folder == 'ROSMAP':
# num_class = 2
# if data_folder == 'BRCA':
# num_class = 5
# if data_folder == 'gbm'or data_folder =='breast2':
# num_class = 4
num_class=typenum
train_test(data_folder, view_list, num_class,
lr_e_pretrain, lr_e, lr_c,
num_epoch_pretrain, num_epoch)
print(datatype+str(typenum)+'\n')
print('*'*100)
# single
# if __name__ == "__main__":
#
#
# data_folder = 'single-cell'
# view_list = [1,2]
# num_epoch_pretrain = 500
# num_epoch = 500
# lr_e_pretrain = 1e-3
# lr_e = 5e-4
# lr_c = 1e-3
#
# # if data_folder == 'ROSMAP':
# # num_class = 2
# # if data_folder == 'BRCA':
# # num_class = 5
# # if data_folder == 'gbm'or data_folder =='breast2':
# # num_class = 4
# num_class=3
# train_test(data_folder, view_list, num_class,
# lr_e_pretrain, lr_e, lr_c,
# num_epoch_pretrain, num_epoch)