如何删除已存在的tensorflow变量?

时间:2017-02-22 04:27:03

标签: tensorflow

我正在使用windows GPU tensorflow 1.0。我想删除无用或错误的tf变量。

For example I run code and generate a bad model, then I copy code and just modify existed variable W1(shape=[3,3],name="W1") as W1(shape=[5,5],name="W1") and run.  

 However tensorflow generate W1(shape=[5,5],name="W1_1") rather than replace old W1. So in the end Tensorflow will save both wrong trained W1(name='w1') and trained w1(name='w1_1'). When I restore W1, tensorflow give me wrong trained W1(name='w1').    

你能告诉我如何删除旧的变量W1并添加新的W1吗?

(换行编辑功能无用)

0 个答案:

没有答案