Use the device plug-in
You can use the sample GPU/FPGA device plug-in available in the framework or develop your own plug-in.
As an example, the new framework includes a sample implementation of Nvidia GPU plug-in supporting the detection of Nvidia GPUs with a customized scheduler, and isolating containers run with both YARN cgroups and Nvidia Docker runtime v2. The examples discussed here are based on the Nvidia sample plug-in.