benderthon/caffe_freeze.py
def save_weights(caffe_def_path, caffemodel_path, inputs, output_path, graph_name='Graph', conv_var_names=None,
                 conv_transpose_var_names=None, use_padding_same=False):
    """Save the weights of the trainable variables, each one in a different file in output_path."""
    with caffe_to_tensorflow_session(caffe_def_path, caffemodel_path, inputs, graph_name=graph_name,
                                     use_padding_same=use_padding_same) as sess:
        tf_freeze.save_weights(sess, output_path, conv_var_names=conv_var_names,
                               conv_transpose_var_names=conv_transpose_var_names)
def save_weights(caffe_def_path, caffemodel_path, inputs, output_path, graph_name='Graph', conv_var_names=None,
                 conv_transpose_var_names=None, use_padding_same=False):
    """Save the weights of the trainable variables, each one in a different file in output_path."""
    with caffe_to_tensorflow_session(caffe_def_path, caffemodel_path, inputs, graph_name=graph_name,
                                     use_padding_same=use_padding_same) as sess:
        tf_freeze.save_weights(sess, output_path, conv_var_names=conv_var_names,
                               conv_transpose_var_names=conv_transpose_var_names)
Save the weights of the trainable variables, each one in a different file in output_path.