Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the performance test for RKNN #1583

Merged
merged 1 commit into from
Jan 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion mmdeploy/apis/inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ def inference_model(model_cfg: Union[str, mmengine.Config],
from mmdeploy.apis.utils import build_task_processor
task_processor = build_task_processor(model_cfg, deploy_cfg, device)

model = task_processor.build_backend_model(backend_files)
model = task_processor.build_backend_model(
backend_files, task_processor.update_data_preprocessor)

input_shape = get_input_shape(deploy_cfg)
model_inputs, _ = task_processor.create_input(img, input_shape)
Expand Down
3 changes: 2 additions & 1 deletion tools/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,8 @@ def main():
dataloader = task_processor.build_dataloader(test_dataloader)

# load the model of the backend
model = task_processor.build_backend_model(args.model)
model = task_processor.build_backend_model(
args.model, task_processor.update_data_preprocessor)
destroy_model = model.destroy
is_device_cpu = (args.device == 'cpu')

Expand Down