Execution settings for a Deep Learning tool. More...
Public Member Functions | |
| None | __init__ (self) |
| Constructs a eVision.EasyDeepLearning.EDeepLearningExecutionSettings. | |
| None | __init__ (self, eVision.EasyDeepLearning.EDeepLearningExecutionSettings other) |
| Copy constructor. | |
| None | CopyTo (self, eVision.EasyDeepLearning.EDeepLearningExecutionSettings other) |
| Copy the object to another one. | |
| None | Load (self, str filePath) |
| Loads the eVision.EasyDeepLearning.EDeepLearningExecutionSettings. | |
| None | Load (self, eVision.ESerializer|None serializer) |
| Loads the eVision.EasyDeepLearning.EDeepLearningExecutionSettings. | |
| None | Save (self, str filePath) |
| Saves the eVision.EasyDeepLearning.EDeepLearningExecutionSettings. | |
| None | Save (self, eVision.ESerializer|None serializer) |
| Saves the eVision.EasyDeepLearning.EDeepLearningExecutionSettings. | |
| str | GetAvailableDeviceName (self, int i) |
| Name of the i-th device of the current engine. | |
| eVision.EasyDeepLearning.EDeepLearningDevice | GetAvailableDevice (self, int i) |
| Gets the i-th eVision.EasyDeepLearning.EDeepLearningDevice of the current engine. | |
| None | SetDevice (self, eVision.EasyDeepLearning.EDeepLearningDevice device) |
| Sets the device with which to run or train the model. | |
| eVision.EasyDeepLearning.EDeepLearningDevice | GetDevice (self, int i) |
| Gets an active device. | |
| eVision.EasyDeepLearning.EDeepLearningDevice | GetDevice (self) |
| Gets an active device. | |
| str | Engine (self) |
| Engine with which to execute or train the neural network. | |
| Engine (self, str value) | |
| Engine with which to execute or train the neural network. | |
| eVision.EasyDeepLearning.EDeepLearningInferencePrecision | InferencePrecision (self) |
| Inference precision. | |
| InferencePrecision (self, eVision.EasyDeepLearning.EDeepLearningInferencePrecision value) | |
| Inference precision. | |
| int | NumAvailableDevices (self) |
| Available devices for the current eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Engine. | |
| list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] | AvailableDevices (self) |
| Get all available device for the current engine. | |
| int | NumDevices (self) |
| Number of devices configured in this execution context. | |
| list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] | Devices (self) |
| Devices with which to run or train the model. | |
| Devices (self, list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] value) | |
| Devices with which to run or train the model. | |
| int | BatchSize (self) |
| Batch size. | |
| BatchSize (self, int value) | |
| Batch size. | |
| bool | OptimizeBatchSize (self) |
| Indicates whether to optimize the batch size (see eVision.EasyDeepLearning.EDeepLearningExecutionSettings.BatchSize) to maximize the training and inference speed according to the engine, device and the available memory. | |
| OptimizeBatchSize (self, bool value) | |
| Indicates whether to optimize the batch size (see eVision.EasyDeepLearning.EDeepLearningExecutionSettings.BatchSize) to maximize the training and inference speed according to the engine, device and the available memory. | |
Static Public Member Functions | |
| int | GetNumAvailableEngines () |
| Number of available engines. | |
| str | GetAvailableEngineName (int id) |
| Gets the name of the engine given its id. | |
| list[str] | GetAvailableEngines () |
| Available engines. | |
| list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] | GetAvailableDevicesForEngine (str engine) |
| Available devices for the specified engine. | |
Protected Member Functions | |
| _DeviceByName__setter (self, str value) | |
| Sets the device with which to run the model using its name. | |
| _DeviceById__setter (self, int value) | |
| Sets the device with which to run the model using its index in the list returned by eVision.EasyDeepLearning.EDeepLearningExecutionSettings.AvailableDevices. | |
Properties | |
| DeviceByName | |
| DeviceById | |
Execution settings for a Deep Learning tool.
Remarks:
License(s): BasicTypes
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.__init__ | ( | self | ) |
Constructs a eVision.EasyDeepLearning.EDeepLearningExecutionSettings.
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.__init__ | ( | self, | |
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings | other ) |
Copy constructor.
| other | The other eVision.EasyDeepLearning.EDeepLearningExecutionSettings that we will copy into this one. |
|
protected |
Sets the device with which to run the model using its index in the list returned by eVision.EasyDeepLearning.EDeepLearningExecutionSettings.AvailableDevices.
|
protected |
Sets the device with which to run the model using its name.
| list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] eVision.EasyDeepLearning.EDeepLearningExecutionSettings.AvailableDevices | ( | self | ) |
Get all available device for the current engine.
| int eVision.EasyDeepLearning.EDeepLearningExecutionSettings.BatchSize | ( | self | ) |
Batch size.
The batch size is the number of images that are processed together during training and batch inference.
When using multi-GPUs processing, the batch size is the number of images that each GPU will process at once.
A large batch size will increase the processing speed on GPU but also the memory requirements.
The batch size must be bigger or equal to 1 and it is commonly chosen to be a power of 2.
Remarks:
If eVision.EasyDeepLearning.EDeepLearningExecutionSettings.OptimizeBatchSize is 'true', then the value of this property will not be taken into account because it will be optimized automatically for training or inference according to the situation.
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings.BatchSize | ( | self, | |
| int | value ) |
Batch size.
The batch size is the number of images that are processed together during training and batch inference.
When using multi-GPUs processing, the batch size is the number of images that each GPU will process at once.
A large batch size will increase the processing speed on GPU but also the memory requirements.
The batch size must be bigger or equal to 1 and it is commonly chosen to be a power of 2.
Remarks:
If eVision.EasyDeepLearning.EDeepLearningExecutionSettings.OptimizeBatchSize is 'true', then the value of this property will not be taken into account because it will be optimized automatically for training or inference according to the situation.
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.CopyTo | ( | self, | |
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings | other ) |
Copy the object to another one.
| other | The other eVision.EasyDeepLearning.EDeepLearningExecutionSettings that we will copy this one into. |
| list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Devices | ( | self | ) |
Devices with which to run or train the model.
Using multiple GPUs is only supported by the default engine.
Remarks:
If the specified devices don't support the current eVision.EasyDeepLearning.EDeepLearningExecutionSettings.InferencePrecision, it will be set to eVision.EasyDeepLearning.EDeepLearningDevice.DefaultPrecision.
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Devices | ( | self, | |
| list[eVision._eVision.EasyDeepLearning.EDeepLearningDevice] | value ) |
Devices with which to run or train the model.
Using multiple GPUs is only supported by the default engine.
Remarks:
If the specified devices don't support the current eVision.EasyDeepLearning.EDeepLearningExecutionSettings.InferencePrecision, it will be set to eVision.EasyDeepLearning.EDeepLearningDevice.DefaultPrecision.
| str eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Engine | ( | self | ) |
Engine with which to execute or train the neural network.
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Engine | ( | self, | |
| str | value ) |
Engine with which to execute or train the neural network.
| eVision.EasyDeepLearning.EDeepLearningDevice eVision.EasyDeepLearning.EDeepLearningExecutionSettings.GetAvailableDevice | ( | self, | |
| int | i ) |
Gets the i-th eVision.EasyDeepLearning.EDeepLearningDevice of the current engine.
| i | Index of the device between 0 and eVision.EasyDeepLearning.EDeepLearningExecutionSettings.NumAvailableDevices - 1. |
| str eVision.EasyDeepLearning.EDeepLearningExecutionSettings.GetAvailableDeviceName | ( | self, | |
| int | i ) |
Name of the i-th device of the current engine.
| i | Index of the device between 0 and eVision.EasyDeepLearning.EDeepLearningExecutionSettings.NumAvailableDevices - 1. |
|
static |
Available devices for the specified engine.
| engine | Engine for which to get the devices |
|
static |
Gets the name of the engine given its id.
| id | Index of the available engine between 0 and eVision.EasyDeepLearning.EDeepLearningExecutionSettings.GetNumAvailableEngines - 1. |
|
static |
Available engines.
| eVision.EasyDeepLearning.EDeepLearningDevice eVision.EasyDeepLearning.EDeepLearningExecutionSettings.GetDevice | ( | self | ) |
Gets an active device.
By default, it returns the first active device.
| eVision.EasyDeepLearning.EDeepLearningDevice eVision.EasyDeepLearning.EDeepLearningExecutionSettings.GetDevice | ( | self, | |
| int | i ) |
Gets an active device.
By default, it returns the first active device.
| i | Index of the active devices between 0 and eVision.EasyDeepLearning.EDeepLearningExecutionSettings.NumDevices. |
|
static |
Number of available engines.
| eVision.EasyDeepLearning.EDeepLearningInferencePrecision eVision.EasyDeepLearning.EDeepLearningExecutionSettings.InferencePrecision | ( | self | ) |
Inference precision.
Use eVision.EasyDeepLearning.EDeepLearningDevice.IsPrecisionSupported to check whether a device support the given precision.
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings.InferencePrecision | ( | self, | |
| eVision.EasyDeepLearning.EDeepLearningInferencePrecision | value ) |
Inference precision.
Use eVision.EasyDeepLearning.EDeepLearningDevice.IsPrecisionSupported to check whether a device support the given precision.
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Load | ( | self, | |
| eVision.ESerializer | None | serializer ) |
Loads the eVision.EasyDeepLearning.EDeepLearningExecutionSettings.
The given eVision.ESerializer must have been created for reading.
Remarks:
Loading a eVision.EasyDeepLearning.EDeepLearningExecutionSettings can trigger exceptions if the engine and/or device is not available on the machine.
| serializer | Pointer to the eVision.ESerializer created for reading. |
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Load | ( | self, | |
| str | filePath ) |
Loads the eVision.EasyDeepLearning.EDeepLearningExecutionSettings.
The given eVision.ESerializer must have been created for reading.
Remarks:
Loading a eVision.EasyDeepLearning.EDeepLearningExecutionSettings can trigger exceptions if the engine and/or device is not available on the machine.
| filePath | File path. |
| int eVision.EasyDeepLearning.EDeepLearningExecutionSettings.NumAvailableDevices | ( | self | ) |
Available devices for the current eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Engine.
| int eVision.EasyDeepLearning.EDeepLearningExecutionSettings.NumDevices | ( | self | ) |
Number of devices configured in this execution context.
| bool eVision.EasyDeepLearning.EDeepLearningExecutionSettings.OptimizeBatchSize | ( | self | ) |
Indicates whether to optimize the batch size (see eVision.EasyDeepLearning.EDeepLearningExecutionSettings.BatchSize) to maximize the training and inference speed according to the engine, device and the available memory.
Default value is true.
| eVision.EasyDeepLearning.EDeepLearningExecutionSettings.OptimizeBatchSize | ( | self, | |
| bool | value ) |
Indicates whether to optimize the batch size (see eVision.EasyDeepLearning.EDeepLearningExecutionSettings.BatchSize) to maximize the training and inference speed according to the engine, device and the available memory.
Default value is true.
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Save | ( | self, | |
| eVision.ESerializer | None | serializer ) |
Saves the eVision.EasyDeepLearning.EDeepLearningExecutionSettings.
The given eVision.ESerializer must have been created for writing.
| serializer | Pointer to the eVision.ESerializer created for writing. |
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.Save | ( | self, | |
| str | filePath ) |
Saves the eVision.EasyDeepLearning.EDeepLearningExecutionSettings.
The given eVision.ESerializer must have been created for writing.
| filePath | File path. |
| None eVision.EasyDeepLearning.EDeepLearningExecutionSettings.SetDevice | ( | self, | |
| eVision.EasyDeepLearning.EDeepLearningDevice | device ) |
Sets the device with which to run or train the model.
Remarks:
For CPU device, the number of thread is initialized from eVision.Easy.SetMaxNumberOfProcessingThreads.
If the specified device does support the current eVision.EasyDeepLearning.EDeepLearningExecutionSettings.InferencePrecision, it will be set to eVision.EasyDeepLearning.EDeepLearningDevice.DefaultPrecision.
| device | Device |
|
static |
|
static |