855d29dba61a53553e8fc89237773368fd7e9cdf,research/object_detection/dataset_tools/context_rcnn/generate_detection_data.py,GenerateDetectionDataFn,_load_inference_model,#GenerateDetectionDataFn#,83
Before Change
self._input = graph.get_tensor_by_name(input_tensor_name)
self._boxes_node = graph.get_tensor_by_name(
signature.outputs["detection_boxes"].name)
self._scores_node = graph.get_tensor_by_name(
signature.outputs["detection_scores"].name)
self._num_detections_node = graph.get_tensor_by_name(
signature.outputs["num_detections"].name)
def process(self, tfrecord_entry):
After Change
// Because initialization of the tf.Session is expensive we share
// one instance across all threads in the worker. This is possible since
// tf.Session.run() is thread safe.
with self.session_lock:
self._detect_fn = tf.saved_model.load(self._model_dir)
def process(self, tfrecord_entry):
return self._run_inference_and_generate_detections(tfrecord_entry)
def _run_inference_and_generate_detections(self, tfrecord_entry):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances Project Name: tensorflow/models
Commit Name: 855d29dba61a53553e8fc89237773368fd7e9cdf
Time: 2020-07-29
Author: sbeery@google.com
File Name: research/object_detection/dataset_tools/context_rcnn/generate_detection_data.py
Class Name: GenerateDetectionDataFn
Method Name: _load_inference_model
Project Name: tensorflow/hub
Commit Name: 0645b446e61e3e51e00c20a2f925111dcd29e264
Time: 2018-07-31
Author: robbie.haertel@gmail.com
File Name: examples/image_retraining/retrain.py
Class Name:
Method Name: export_model
Project Name: tensorflow/minigo
Commit Name: 39a106e526e70b5d64bf9f5404311eb490df6ea5
Time: 2018-06-12
Author: tmadams@google.com
File Name: inference_worker.py
Class Name:
Method Name: main