|
OpenNN
Open-source neural networks library
|
Global singleton holding the OpenNN device and precision configuration. More...
#include <configuration.h>
Classes | |
| struct | Resolved |
| Resolved configuration after Auto values are mapped to concrete device and types. More... | |
Public Member Functions | |
| void | set (Device new_device=Device::Auto, Type new_training_type=Type::Auto, Type new_inference_type=Type::Auto) |
| Updates device and precision settings; subsequent resolve() calls reflect the change. | |
| Device | get_device () const |
| Type | get_training_type () const |
| Type | get_inference_type () const |
| const Resolved & | resolve () const |
| Returns the cached resolved configuration, computing it on first access. | |
| bool | is_gpu () const |
| bool | is_cpu () const |
| bool | is_bf16_training () const |
| bool | is_bf16_inference () const |
Static Public Member Functions | |
| static Configuration & | instance () |
| Returns the process-wide Configuration singleton. | |
Global singleton holding the OpenNN device and precision configuration.
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinestaticnodiscard |
Returns the process-wide Configuration singleton.
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
Returns the cached resolved configuration, computing it on first access.
| void opennn::Configuration::set | ( | Device | new_device = Device::Auto, |
| Type | new_training_type = Type::Auto, | ||
| Type | new_inference_type = Type::Auto ) |
Updates device and precision settings; subsequent resolve() calls reflect the change.
| new_device | Target execution device (Auto picks CUDA when available). |
| new_training_type | Numeric type used during training. |
| new_inference_type | Numeric type used during inference. |