Face Engine SDK  5.11.0
A face detection, recognition and tracking engine.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
ICrowdEstimator.h
1 #pragma once
2 
3 #include <fsdk/Def.h>
4 #include <fsdk/FSDKError.h>
5 #include <fsdk/IRefCounted.h>
6 #include <fsdk/Types/Image.h>
7 #include <fsdk/Types/Ref.h>
8 #include <fsdk/Types/Result.h>
9 #include <fsdk/Types/Span.h>
10 
11 namespace fsdk {
12 
13 #ifndef DOXYGEN_SHOULD_SKIP_THIS
14  DECLARE_SMARTPTR(ICrowdEstimator);
15 #endif
16 
24  CET_COUNT
25  };
26 
31  struct CrowdEstimation {
32  size_t count;
33  };
34 
51  virtual Result<FSDKError>
52  estimate(
53  const Image& image,
54  const Rect& rect,
55  CrowdEstimation& estimation) const noexcept = 0;
56 
69  virtual Result<FSDKError>
70  estimate(
71  Span<const Image> images,
72  Span<const Rect> rects,
73  Span<CrowdEstimation> estimations) const noexcept = 0;
74 
86  virtual Result<FSDKError>
87  validate(
88  Span<const Image> images,
89  Span<const Rect> rects,
90  Span<Result<FSDKError>> errors) const noexcept = 0;
91 
97  virtual CrowdEstimatorType
98  getType() const noexcept = 0;
99  };
100 
101 } // namespace fsdk
#define DECLARE_SMARTPTR(X)
Smart ptr declaration helper macro.
Definition: Def.h:59
A structure that encapsulates an action result enumeration.
Definition: Result.h:29
Single network mode - only Crowd estimation will be used.
Definition: ICrowdEstimator.h:22
virtual CrowdEstimatorType getType() const noexcept=0
Returns a type of the estimator.
Crowd estimation structure.
Definition: ICrowdEstimator.h:31
size_t count
The number of peoples (heads) on the image.
Definition: ICrowdEstimator.h:32
Common SDK error codes.
Base strong reference counted object interface.
Definition: IRefCounted.h:36
virtual Result< FSDKError > estimate(const Image &image, const Rect &rect, CrowdEstimation &estimation) const noexcept=0
Estimates the crowd on the target image.
Common SDK definitions.
Double network mode - Crowd + HeadDetector.
Definition: ICrowdEstimator.h:23
Default type which is specified in config file.
Definition: ICrowdEstimator.h:21
Crowd estimator interface.
Definition: ICrowdEstimator.h:41
Image.
Definition: Image.h:38
virtual Result< FSDKError > validate(Span< const Image > images, Span< const Rect > rects, Span< Result< FSDKError >> errors) const noexcept=0
Validate input of multiple frames in a single function call.
CrowdEstimatorType
CrowdEstimator type enumeration.
Definition: ICrowdEstimator.h:20
Span. Not owning data view. It incapsulated pointer to the continuous array with one or more T objec...
Definition: Span.h:14
Reference counted object interface.