          """ Return all listed Nvidia handles """
          if self.plaid is not None:
              self.handles = self.plaid.devices
          elif IS_MACOS:
              self.handles = pynvx.cudaDeviceGetHandles(ignore=True)
          else:
              self.handles = [pynvml.nvmlDeviceGetHandleByIndex(i)
                              for i in range(self.device_count)]
          if self.logger:
              self.logger.debug("GPU Handles found: %s", len(self.handles))
 
</s> remove             self.handles = [pynvml.nvmlDeviceGetHandleByIndex(i)
                            for i in range(self.device_count)]
        if self.logger:
            self.logger.debug("GPU Handles found: %s", len(self.handles))

    def get_driver(self):
        """ Get the driver version """
        if self.plaid is not None:
            driver = self.plaid.drivers
 </s> add             self._handles = [pynvml.nvmlDeviceGetHandleByIndex(i)
                             for i in range(self._device_count)]
        self._log("debug", "GPU Handles found: {}".format(len(self._handles)))

    def _get_driver(self):
        """ Obtain and return the installed driver version for the system's GPUs.

        Returns
        -------
        str
            The currently installed GPU driver version
        """
        if self._is_plaidml:
            driver = self._plaid.drivers </s> remove                 self.active_devices = list(range(self.device_count))
            if self.logger:
                self.logger.debug("Active GPU Devices: %s", self.active_devices)

    def get_handles(self):
        """ Return all listed Nvidia handles """
        if self.plaid is not None:
            self.handles = self.plaid.devices
 </s> add                 self._active_devices = list(range(self._device_count))
            self._log("debug", "Active GPU Devices: {}".format(self._active_devices))

    def _get_handles(self):
        """ Obtain the internal handle identifiers for the system GPUs and allocate to
        :attr:`_handles`. """
        if self._is_plaidml:
            self._handles = self._plaid.devices </s> remove             self.initialized = False
 </s> add             self._initialized = False </s> remove                      for handle in self.handles]
 </s> add                      for handle in self._handles] </s> remove             self.device_count = pynvx.cudaDeviceGetCount(ignore=True)
 </s> add             self._device_count = pynvx.cudaDeviceGetCount(ignore=True)
            self._handles = pynvx.cudaDeviceGetHandles(ignore=True)
          """ Return all listed Nvidia handles """
          if self.plaid is not None:
              self.handles = self.plaid.devices
          elif IS_MACOS:
            self._handles = pynvx.cudaDeviceGetHandles(ignore=True)
          else:
              self.handles = [pynvml.nvmlDeviceGetHandleByIndex(i)
                              for i in range(self.device_count)]
          if self.logger:
              self.logger.debug("GPU Handles found: %s", len(self.handles))
keep keep keep keep replace keep keep keep keep keep
 Core Updates (#1015)

- Remove lib.utils.keras_backend_quiet and replace with get_backend() where relevant
- Document lib.gpu_stats and lib.sys_info
- Remove call to GPUStats.is_plaidml from convert and replace with get_backend()
- lib.gui.menu - typofix 
lib/gpu_stats.py