setGpuLayers

public final void setGpuLayers(int value)

Model layers to offload to GPU; 0 is pure CPU. The default value is 99, which offloads all available layers. The GPU is used through Metal on macOS, Direct3D 12 on Windows, and Vulkan on Linux, or CUDA on Linux x64 with an NVIDIA GPU.

Parameters

value

The value to set for the GpuLayers property.