不加载相关优化器参数
vl = [v for v in tf.global_variables() if “Adam/RMSprop” not in v.name]
saver = tf.train.Saver(var_list=vl)
tensorflow finetune:freeze后 ckpt中缺少RMSprop or Adam参数的解决办法
最新推荐文章于 2024-05-06 21:57:58 发布
不加载相关优化器参数
vl = [v for v in tf.global_variables() if “Adam/RMSprop” not in v.name]
saver = tf.train.Saver(var_list=vl)