#!/bin/sh
model="configs/abide_schaefer100/TUs_graph_classification_ContrastPool_abide_schaefer100_100k.json"
echo ${model}
python main.py --config $model --gpu_id 0 --node_feat_transform pearson --max_time 60 --init_lr 1e-2 --threshold 0.0 --batch_size 20 --dropout 0.0 --contrast --pool_ratio 0.5 --lambda1 1e-3 --L 2
2
#!/bin/sh这个是用来声明解释器的,可能linux下有多种解释器吧,需要声明为sh解释器。
而在win环境下,不需要这一句来声明解释器。
3
model="configs/abide_schaefer100/TUs_graph_classification_ContrastPool_abide_schaefer100_100k.json"这句话是声明model所对应的配置文件。
set model="configs\abide_schaefer100\TUs_graph_classification_ContrastPool_abide_schaefer100_100k.json"
从linux环境下转换为win环境下需要加一个set关键字,另外就是修改一下反斜杠。
4
echo ${model}
这句话其实就是输出model的路径,转换为win环境下为:
echo %model%
5
python main.py --config $model --gpu_id 0 --node_feat_transform pearson --max_time 60 --init_lr 1e-2 --threshold 0.0 --batch_size 20 --dropout 0.0 --contrast --pool_ratio 0.5 --lambda1 1e-3 --L 2
这段其实就是设置了一系列参数:如设置model,使用的gpu,
python main.py --config "%model%" --gpu_id 0 --node_feat_transform pearson --max_time 60 --init_lr 1e-2 --threshold 0.0 --batch_size 20 --dropout 0.0 --contrast --pool_ratio 0.5 --lambda1 1e-3 --L 2
6
这样来看,其实要修改的部分并不是很多。
@echo off
set model="configs\abide_schaefer100\TUs_graph_classification_ContrastPool_abide_schaefer100_100k.json"
python main.py --config "%model%" --gpu_id 0 --node_feat_transform pearson --max_time 60 --init_lr 1e-2 --threshold 0.0 --batch_size 20 --dropout 0.0 --contrast --pool_ratio 0.5 --lambda1 1e-3 --L 2