更新时间:2023-12-02 11:48:52
You can fetch the variables as NumPy arrays, and use numpy.savetxt()
to write out the contents as text or CSV:
import numpy as np
W_val, b_val = sess.run([W, b])
np.savetxt("W.csv", W_val, delimiter=",")
np.savetxt("b.csv", b_val, delimiter=",")
请注意,在 查看全文