I have trained a custom neural network with the function:
tf.estimator.train_and_evaluate
After correct training, it contains the following files:
- checkpoint
- events.out.tfevents.1538489166.ti
- model.ckpt-0.data-00000-of-00002
- model.ckpt-0.index
- model.ckpt-10.data-00000-of-00002
- model.ckpt-10.index eval
- graph.pbtxt
- model.ckpt-0.data-00001-of-00002
- model.ckpt-0.meta
- model.ckpt-10.data-00001-of-00002
- model.ckpt-10.meta
Now I need to export the weights and biases of every layer, into a raw data structure, e.g. an array, numpy
.
I have read multiple pages on TensorFlow, and on other topics, but neither can find this question. The first thing I would assume to put the fils together into graph.pd
with the freeze.py as suggested here:
Tensorflow: How to convert .meta, .data and .index model files into one graph.pb file
But then still the main question is unsolved.