Namespace with core LightlyEdge SDK functionality.
More...
|
const size_t | BUFFER_MAX_LENGTH = 3000 |
|
const uint32_t | MAX_CLASSIFICATIONS_DEFAULT = 5 |
|
const int | CPP_SDK_ERROR_CODE = 30 |
|
Namespace with core LightlyEdge SDK functionality.
◆ value_or_throw()
Convenience function to unwrap a result of lightly_edge_sdk::LightlyEdge functions.
Extracts and returns the value from a tl::expected<T, lightly_edge_sdk::Error>
object using move semantics, or throws lightly_edge_sdk::Exception if it contains an error.
This function can be useful if your application uses exceptions for error handling.
Example usage:
auto result = lightly_edge.embed_frame(frame);
static auto new_from_tar(const char *archive_path, LightlyEdgeConfig config) -> LightlyEdge
Initialize LightlyEdge with an ort embedding inference backend.
Definition lightly_edge_sdk.h:170
auto value_or_throw(tl::expected< T, lightly_edge_sdk::Error > &&result) -> T
Convenience function to unwrap a result of lightly_edge_sdk::LightlyEdge functions.
Definition lightly_edge_error.h:79
- Parameters
-
result | The tl::expected object to unwrap. |
- Returns
- The value of the expected object.
- Exceptions
-