vitis::ai::PlateDetect - 2.0 English

Vitis AI Library User Guide (UG1354)

Document ID
UG1354
Release Date
2022-01-20
Version
2.0 English
Base class for detecting the position of plate in a vehicle image (cv::Mat).

Input is a vehicle image (cv::Mat).

Output is position and score of plate in the input image.

Sample code:

cv::Mat image = cv::imread("car.jpg");
auto network = vitis::ai::PlateDetect::create(true);
auto r = network->run(image);
auto score = r.box.score.
auto x = r.box.x * image.cols;
auto y = r.box.y * image.rows;
auto witdh = r.box.width * image.cols;
auto height = r.box.height * image.rows;

Quick Function Reference

The following table lists all the functions defined in the vitis::ai::PlateDetect class:

Table 1. Quick Function Reference
Type Name Arguments
std::unique_ptr< PlateDetect > create
  • bool need_mean_scale_process
std::unique_ptr< PlateDetect > create
  • void
  PlateDetect
  • void
  PlateDetect
  • void
PlateDetect & operator=
  • void
  ~PlateDetect
  • void
int getInputWidth
  • void
int getInputHeight
  • void
size_t get_input_batch
  • void
PlateDetectResult run
  • const cv::Mat & image
std::vector< PlateDetectResult > run
  • const std::vector< cv::Mat > & images