15a86d278c6b0f8574cdd6e237f778faf2e002e1,solutionbox/inception/datalab_solutions/inception/_model.py,Model,export,#Model#Any#Any#,324

Before Change


                                   last_checkpoint)
      saver = tf.train.Saver()
      saver.export_meta_graph(filename=os.path.join(output_dir, "export.meta"))
      saver.save(sess, os.path.join(output_dir, "export"), write_meta_graph=False)

  def format_metric_values(self, metric_values):
    Formats metric values - used for logging purpose.

After Change


      sess.run(init_op)
      self.restore_from_checkpoint(sess, self.inception_checkpoint_file,
                                   last_checkpoint)
      init_op_serving = control_flow_ops.group(
          variables.local_variables_initializer(),
          data_flow_ops.tables_initializer())

      builder = saved_model_builder.SavedModelBuilder(output_dir)
      builder.add_meta_graph_and_variables(
          sess, [tag_constants.SERVING],
          signature_def_map=signature_def_map,
          legacy_init_op=init_op_serving)
      builder.save(False)

  def format_metric_values(self, metric_values):
    Formats metric values - used for logging purpose.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 11

Instances


Project Name: googledatalab/pydatalab
Commit Name: 15a86d278c6b0f8574cdd6e237f778faf2e002e1
Time: 2017-02-27
Author: qimingj@users.noreply.github.com
File Name: solutionbox/inception/datalab_solutions/inception/_model.py
Class Name: Model
Method Name: export


Project Name: googledatalab/pydatalab
Commit Name: 15a86d278c6b0f8574cdd6e237f778faf2e002e1
Time: 2017-02-27
Author: qimingj@users.noreply.github.com
File Name: solutionbox/inception/datalab_solutions/inception/_model.py
Class Name: Model
Method Name: export


Project Name: GoogleCloudPlatform/cloudml-samples
Commit Name: 01ed847eea06300d278ffcf1214021b487d3d463
Time: 2017-03-07
Author: elibixby@google.com
File Name: mnist/distributed/trainer/model.py
Class Name: Model
Method Name: export


Project Name: GoogleCloudPlatform/cloudml-samples
Commit Name: 01ed847eea06300d278ffcf1214021b487d3d463
Time: 2017-03-07
Author: elibixby@google.com
File Name: flowers/trainer/model.py
Class Name: Model
Method Name: export