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

[Model] Support Paddle3D PETR v2 model #1863

Merged
merged 21 commits into from
May 19, 2023
Merged

Conversation

CoolKbh
Copy link
Contributor

@CoolKbh CoolKbh commented Apr 24, 2023


运行完成可视化结果如下图所示

<img width="640" src="https://user-images.githubusercontent.com/30516196/230387825-53ac0a09-4137-4e49-9564-197cbc30ff08.png">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PETR已经支持可视化了吗?这个是不是smoke 3d的?如果PETR还没支持可视化,这个图先删除吧

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

fastdeploy.vision.detection.Smoke(model_file, params_file, config_file, runtime_option=None, model_format=ModelFormat.PADDLE)
```

Smoke model loading and initialization.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里还是smoke的文档,更新成petr的吧

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@@ -0,0 +1,68 @@
[English](README.md) | 简体中文

# Smoke Python 部署示例
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同上,文档更新成petr的

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

config_file = os.path.join(args.model, "infer_cfg.yml")
# 配置runtime,加载模型
runtime_option = build_option(args)
model = fd.vision.perception.Smoke(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里还是smoke的,python案例也更新成petr的

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@@ -0,0 +1,85 @@
English | [简体中文](README_CN.md)
# Smoke service deployment example
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

服务化还没测试过,先删除服务化的案例吧

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

*/
bool Apply(FDMatBatch* image_batch, std::vector<FDTensor>* outputs);

void normalize(cv::Mat *im, const std::vector<float> &mean,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

函数风格采用首字符大写驼峰法

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Collaborator

@DefTruth DefTruth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM~

@DefTruth DefTruth changed the title [MODEL] Support PETR v2 [Model] Support Paddle3D PETR v2 model May 19, 2023
@DefTruth DefTruth merged commit e3b285c into PaddlePaddle:develop May 19, 2023
1 check passed
DefTruth added a commit that referenced this pull request May 19, 2023
* Support PETR v2

* make petrv2 precision equal with the origin repo

* delete extra func

* modify review problem

* delete visualize

* Update README_CN.md

* Update README.md

* Update README_CN.md

* fix build problem

* delete external variable and function

---------

Co-authored-by: DefTruth <[email protected]>
DefTruth added a commit that referenced this pull request May 19, 2023
* Support PETR v2

* make petrv2 precision equal with the origin repo

* delete extra func

* modify review problem

* delete visualize

* Update README_CN.md

* Update README.md

* Update README_CN.md

* fix build problem

* delete external variable and function

---------

Co-authored-by: DefTruth <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants