forked from OSSInnovation/mindspore
!6789 fix int in ckpt name changed to float bug
Merge pull request !6789 from caozhou/fix_ckpt_name_float
This commit is contained in:
commit
04e2ab1b0b
|
@ -276,7 +276,7 @@ class ModelCheckpoint(Callback):
|
||||||
return
|
return
|
||||||
|
|
||||||
save_ckpt = self._check_save_ckpt(cb_params, force_to_save)
|
save_ckpt = self._check_save_ckpt(cb_params, force_to_save)
|
||||||
step_num_in_epoch = (cb_params.cur_step_num - 1) % cb_params.batch_num + 1
|
step_num_in_epoch = int((cb_params.cur_step_num - 1) % cb_params.batch_num + 1)
|
||||||
|
|
||||||
if save_ckpt:
|
if save_ckpt:
|
||||||
cur_ckpoint_file = self._prefix + "-" + str(cb_params.cur_epoch_num) + "_" \
|
cur_ckpoint_file = self._prefix + "-" + str(cb_params.cur_epoch_num) + "_" \
|
||||||
|
|
Loading…
Reference in New Issue