How to save optimiser state and the model of CGAN?

link : model-zoo/cGAN_mnist.jl at master · FluxML/model-zoo · GitHub

i tried inside training loop:

@save "gen-model-$(now()).bson" gen opt_gen
@save "dscr-model-$(now()).bson" dscr opt_dscr
ERROR: LoadError: SystemError: opening file "genmodel-2021-08-28T17:18:44.080.bson": Invalid argument