forked from mindspore-Ecosystem/mindspore
!2940 fix gat train fail caused by checkpoint permission and missing data path in README.MD
Merge pull request !2940 from zhangdengcheng/master
This commit is contained in:
commit
fdc3a235e6
|
@ -72,9 +72,9 @@ sh run_process_data.sh [SRC_PATH] [DATASET_NAME]
|
||||||
>> Launch
|
>> Launch
|
||||||
```
|
```
|
||||||
#Generate dataset in mindrecord format for cora
|
#Generate dataset in mindrecord format for cora
|
||||||
sh run_process_data.sh cora
|
./run_process_data.sh ./data cora
|
||||||
#Generate dataset in mindrecord format for citeseer
|
#Generate dataset in mindrecord format for citeseer
|
||||||
sh run_process_data.sh citeseer
|
./run_process_data.sh ./data citeseer
|
||||||
```
|
```
|
||||||
|
|
||||||
# Features
|
# Features
|
||||||
|
|
|
@ -96,6 +96,8 @@ def train():
|
||||||
if eval_acc >= val_acc_max and eval_loss < val_loss_min:
|
if eval_acc >= val_acc_max and eval_loss < val_loss_min:
|
||||||
val_acc_model = eval_acc
|
val_acc_model = eval_acc
|
||||||
val_loss_model = eval_loss
|
val_loss_model = eval_loss
|
||||||
|
if os.path.exists("ckpts/gat.ckpt"):
|
||||||
|
os.remove("ckpts/gat.ckpt")
|
||||||
_exec_save_checkpoint(train_net.network, "ckpts/gat.ckpt")
|
_exec_save_checkpoint(train_net.network, "ckpts/gat.ckpt")
|
||||||
val_acc_max = np.max((val_acc_max, eval_acc))
|
val_acc_max = np.max((val_acc_max, eval_acc))
|
||||||
val_loss_min = np.min((val_loss_min, eval_loss))
|
val_loss_min = np.min((val_loss_min, eval_loss))
|
||||||
|
|
Loading…
Reference in New Issue