Skip to content

Commit b640618

Browse files
committed
Merge the recent two missing changes.
1 parent 51f6b20 commit b640618

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

efficientdet/keras/inference.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,8 +219,9 @@ def benchmark(self, image_arrays, bm_runs=10, trace_filename=None):
219219
bm_runs: Number of benchmark runs.
220220
trace_filename: If None, specify the filename for saving trace.
221221
"""
222+
_, spec = self._get_model_and_spec()
222223

223-
@tf.function
224+
@tf.function(input_signature=[spec])
224225
def test_func(image_arrays):
225226
return self.model(image_arrays) # pylint: disable=not-callable
226227

efficientdet/keras/inspector.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ def main(_):
163163
boxes[0],
164164
classes[0],
165165
scores[0],
166-
min_score_thresh=model_config.nms_configs.score_thresh,
166+
min_score_thresh=model_config.nms_configs.score_thresh or 0.4,
167167
max_boxes_to_draw=model_config.nms_configs.max_output_size)
168168

169169
if out_ptr:

efficientdet/keras/train_lib.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ def get_callbacks(params, val_dataset=None):
407407
"""Get callbacks for given params."""
408408
if params['moving_average_decay']:
409409
avg_callback = AverageModelCheckpoint(
410-
filepath=os.path.join(params['model_dir'], 'ckpt'),
410+
filepath=os.path.join(params['model_dir'], 'ema_ckpt'),
411411
verbose=1,
412412
save_weights_only=True,
413413
update_weights=False)

0 commit comments

Comments
 (0)