From 2a2644d646c30f9c20bf41ee900e19b254bf2d5e Mon Sep 17 00:00:00 2001 From: Wenyu Date: Sun, 1 Aug 2021 17:03:02 +0800 Subject: [PATCH] Fix args for infer (#3840) --- configs/sparse_rcnn/_base_/sparse_rcnn_reader.yml | 2 +- ppdet/data/transform/batch_operators.py | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/configs/sparse_rcnn/_base_/sparse_rcnn_reader.yml b/configs/sparse_rcnn/_base_/sparse_rcnn_reader.yml index f4226473d..248ca39b7 100644 --- a/configs/sparse_rcnn/_base_/sparse_rcnn_reader.yml +++ b/configs/sparse_rcnn/_base_/sparse_rcnn_reader.yml @@ -39,6 +39,6 @@ TestReader: - Permute: {} batch_transforms: - PadBatch: {pad_to_stride: 32} - - Gt2SparseRCNNTarget: {train: false} + - Gt2SparseRCNNTarget: {} batch_size: 1 shuffle: false diff --git a/ppdet/data/transform/batch_operators.py b/ppdet/data/transform/batch_operators.py index 81b5ef728..bacd53b75 100644 --- a/ppdet/data/transform/batch_operators.py +++ b/ppdet/data/transform/batch_operators.py @@ -767,7 +767,6 @@ class Gt2SparseRCNNTarget(BaseOperator): sample["scale_factor_wh"] = np.array( [sample["scale_factor"][1], sample["scale_factor"][0]], dtype=np.float32) - sample.pop("scale_factor") else: sample["scale_factor_wh"] = np.array( [1.0, 1.0], dtype=np.float32) -- GitLab