vitis::ai::BCC - 1.4 English

Vitis AI Library User Guide (UG1354)

Document ID
UG1354
Release Date
2021-07-22
Version
1.4 English
Base class for BCC (Bayesian crowd counting)

Input is an image (cv:Mat).

Output is a struct of detection results, named BCCResult.

Sample code :

Mat img = cv::imread("sample_BCC.jpg");
auto BCC = vitis::ai::BCC::create("bcc_pt",true);
auto result = BCC->run(img);
std::cout << result.count << "\n";

Quick Function Reference

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

Table 1. Quick Function Reference
Type Name Arguments
std::unique_ptr< BCC > create
  • const std::string & model_name
  • bool need_preprocess
vitis::ai::BCCResult run
  • const cv::Mat & img
std::vector< vitis::ai::BCCResult > run
  • const std::vector< cv::Mat > & imgs
int getInputWidth
  • void
int getInputHeight
  • void
size_t get_input_batch
  • void