class_docstr: Base class for samplers used to generate from the VAEs models.
  
  Args:
      model (BaseAE): The vae model to sample from.
      sampler_config (BaseSamplerConfig): An instance of BaseSamplerConfig in which any sampler's
          parameters is made available. If None a default configuration is used. Default: None
class_docstr_tok: ["Base","class","for","samplers","used","to","generate","from","the","VAEs","models",".","Args",":","model","(","BaseAE",")",":","The","vae","model","to","sample","from",".","sampler_config","(","BaseSamplerConfig",")",":","An","instance","of","BaseSamplerConfig","in","which","any","sampler's","parameters","is","made","available",".","If","None","a","default","configuration","is","used",".","Default",":","None"]
code: def _set_inputs_to_device(self, inputs: Dict[str, Any]):
      inputs_on_device = inputs
  
      if self.device == "cuda":
          cuda_inputs = dict.fromkeys(inputs)
  
          for key in inputs.keys():
              if torch.is_tensor(inputs[key]):
                  cuda_inputs[key] = inputs[key].cuda()
  
              else:
                  cuda_inputs[key] = inputs[key]
          inputs_on_device = cuda_inputs
  
      return inputs_on_device
  
file_path: benchmark_VAE/src/pythae/samplers/base/base_sampler.py
imports: import logging
  import os
  from typing import Any, Dict
  import numpy
  import torch
  from imageio import imwrite
  from ...models import BaseAE
  from .base_sampler_config import BaseSamplerConfig
label_desc: Use image node_id 6 for calling the BaseSampler obj's underlying member method code with example usage: obj._set_inputs_to_device(inputs) and returns: inputs_on_device