| Face Engine SDK 5.12.0 A face detection, recognition and tracking engine.

FSDKError.h
Go to the documentation of this file.
1
8 #pragma once
9
10 #include <fsdk/Types/Result.h>
11
12 namespace fsdk {
13
17 enum class FSDKError : uint32_t {
18 Ok,
19 Internal,
20 InvalidInput,
21 InvalidImage,
22
23 InvalidRect,
24 InvalidImageFormat,
25 InvalidImageSize,
26 InvalidDetection,
27 InvalidLandmarks5,
28 InvalidLandmarks68,
29 InvalidTransformation,
30 InvalidDescriptor,
31 InvalidDescriptorBatch,
32 InvalidSettingsProvider,
33 InvalidDescriptorId,
34 InvalidPath,
35 InvalidSerializedObject,
36
37 ModuleNotInitialized,
38 ModuleNotReady,
39 LicenseError,
40
41 BufferIsNull,
42 BufferIsFull,
43 BufferIsEmpty,
44 InvalidBufferSize,
45 InvalidSpanSize,
46 InvalidBatch,
47
48 IncompatibleDescriptors,
49 EnableJustInBetaMode,
50
51 FiltredAggregationError,
52
53 BatchedInternalError,
54 UnsupportedFunctionality, // !< was requested unsupported functionality for this type of descroptor or for this model version
55
56 HighMemoryUsage, // !< Operation required a lot of memory. Batch size if too big for example.
57
58 IncompatibleModelVersions,
59 ModelNotLoaded,
60 InvalidConfig,
61 LicenseIsNotActivated,
62 FeatureNotAvailable,
63 FeatureExpired,
64 FingerprintError,
65 ValidationFailed,
66
67 NotImplemented,
68 };
69
73 template<>
74 struct ErrorTraits<FSDKError> {
75
76 static bool isOk(FSDKError error) noexcept {
77 return error == FSDKError::Ok;
78 }
79
80 static const char* toString (FSDKError error) noexcept {
81 switch(error) {
82 case FSDKError::Ok: return "Ok";
83 case FSDKError::Internal: return "Internal error";
84 case FSDKError::InvalidInput: return "Invalid input";
85 case FSDKError::InvalidImage: return "Invalid image";
86 case FSDKError::InvalidRect: return "Invalid rectangle";
87 case FSDKError::InvalidImageFormat: return "Invalid image format";
88 case FSDKError::InvalidImageSize: return "Invalid image size";
89 case FSDKError::InvalidDetection: return "Invalid detection";
90 case FSDKError::InvalidLandmarks5: return "Invalid landmarks 5";
91 case FSDKError::InvalidLandmarks68: return "Invalid landmarks 68";
92 case FSDKError::InvalidTransformation: return "Invalid transformation.";
93 case FSDKError::InvalidDescriptor: return "Invalid descriptor";
94 case FSDKError::InvalidDescriptorBatch: return "Invalid descriptor batch.";
95 case FSDKError::InvalidSettingsProvider: return "Invalid settings provider..";
96 case FSDKError::InvalidDescriptorId: return "Invalid descriptor id.";
97 case FSDKError::InvalidPath: return "Invalid path.";
98 case FSDKError::InvalidSerializedObject: return "Invalid serialized object.";
99 case FSDKError::ModuleNotInitialized: return "Module is not initialized";
100 case FSDKError::ModuleNotReady: return "Module is not ready";
101 case FSDKError::LicenseError: return "Licensing issue";
102 case FSDKError::BufferIsNull: return "Buffer is null";
103 case FSDKError::BufferIsFull: return "Buffer is full";
104 case FSDKError::BufferIsEmpty: return "Buffer is empty";
105 case FSDKError::InvalidBufferSize: return "Invalid buffer size";
106 case FSDKError::InvalidSpanSize: return "Invalid span size";
107 case FSDKError::InvalidBatch: return "Invalid Batch";
108 case FSDKError::IncompatibleDescriptors: return "Descriptors are incompatible";
109 case FSDKError::EnableJustInBetaMode: return "Attempt to create feature while betaMode is turned off";
110 case FSDKError::FiltredAggregationError: return "Cant aggregate descriptors - all images'a GSs are less the threashold";
111 case FSDKError::BatchedInternalError: return "Something gone wrong in batched query";
112 case FSDKError::UnsupportedFunctionality: return "Was requested unsupported functionality";
113 case FSDKError::HighMemoryUsage: return "Operation required a lot of memory";
114 case FSDKError::IncompatibleModelVersions: return "Incompatible model versions";
115 case FSDKError::ModelNotLoaded: return "Model not loaded";
116 case FSDKError::InvalidConfig: return "Invalid config";
117 case FSDKError::LicenseIsNotActivated: return "License is not activated!";
118 case FSDKError::FeatureNotAvailable: return "Requested Feature not available.";
119 case FSDKError::FeatureExpired: return "Feature is expired.";
120 case FSDKError::FingerprintError: return "Failed to get device fingerprint.";
121 case FSDKError::ValidationFailed: return "Failed validation.";
122 case FSDKError::NotImplemented: return "Not implemented.";
123 default: return "Unknown error";
124 }
125 }
126 };
127
128 }
fsdk::FSDKError::InvalidSerializedObject
Invalid serialized object.
fsdk::FSDKError::ValidationFailed
Failed validation.
fsdk::FSDKError::InvalidDescriptor
Invalid descriptor.
fsdk
SDK namespace.
Definition: IAGSEstimator.h:8
fsdk::FSDKError::FiltredAggregationError
Cant aggregate descriptors - all images&#39;a GSs are less the threashold.
fsdk::FSDKError::FeatureExpired
Feature expired.
fsdk::FSDKError::IncompatibleDescriptors
Matching attempt with incompatible descriptors.
fsdk::FSDKError::NotImplemented
Not implemented error.
fsdk::FSDKError::InvalidInput
Invalid input.
fsdk::FSDKError::InvalidDescriptorBatch
Invalid descriptor batch.
fsdk::FSDKError::BufferIsEmpty
Buffer is empty.
fsdk::FSDKError::InvalidSettingsProvider
Invalid settings provider.
fsdk::FSDKError::InvalidImageFormat
Invalid image format.
fsdk::FSDKError::ModuleNotReady
Module is not ready.
fsdk::FSDKError::Internal
Internal error.
fsdk::FSDKError::InvalidPath
Invalid path to object.
fsdk::ErrorTraits
Definition: Result.h:9
fsdk::FSDKError::ModelNotLoaded
Model not loaded.
fsdk::FSDKError::InvalidTransformation
Invalid transformation.
fsdk::FSDKError::InvalidLandmarks5
Invalid landmarks 5.
fsdk::FSDKError::Ok
Ok.
fsdk::FSDKError::FeatureNotAvailable
Requested Feature not available.
fsdk::FSDKError::InvalidBufferSize
Invalid buffer size.
fsdk::FSDKError::BufferIsFull
Buffer is full.
fsdk::FSDKError::InvalidDetection
Invalid detection.
fsdk::FSDKError::InvalidDescriptorId
Invalid descriptor id.
fsdk::FSDKError::InvalidImage
Invalid image.
fsdk::FSDKError::LicenseIsNotActivated
License is not activated.
fsdk::FSDKError::LicenseError
Licensing issue (expired license or unavailable feature).
fsdk::FSDKError::InvalidBatch
Invalid batch.
fsdk::FSDKError::IncompatibleModelVersions
Incompatible model versions.
fsdk::FSDKError::ModuleNotInitialized
Module is not initialized.
fsdk::FSDKError::InvalidSpanSize
Invalid span size.
fsdk::FSDKError::InvalidLandmarks68
Invalid landmarks 68.
fsdk::FSDKError
FSDKError
Common SDK error codes.
Definition: FSDKError.h:17
fsdk::FSDKError::InvalidRect
Invalid rectangle.
fsdk::FSDKError::InvalidImageSize
Invalid image size.
fsdk::FSDKError::BufferIsNull
Buffer is null.
fsdk::FSDKError::EnableJustInBetaMode
Attempt to create feature while betaMode is turned off.
fsdk::FSDKError::FingerprintError
Failed to get device fingerprint.
fsdk::FSDKError::InvalidConfig
Invalid config.
fsdk::FSDKError::BatchedInternalError
Something gone wrong in batched query. See batch with error codes to each input image for details...