code: def ready_argument_list(self, arguments):
          
          gpu_args = []
          for arg in arguments:
              # if arg i is a numpy array copy to device
              if isinstance(arg, numpy.ndarray):
                  gpu_args.append(cl.Buffer(self.ctx, self.mf.READ_WRITE | self.mf.COPY_HOST_PTR, hostbuf=arg))
              else: # if not an array, just pass argument along
                  gpu_args.append(arg)
          return gpu_args
docs: ready argument list to be passed to the kernel, allocates gpu mem
  
          :param arguments: List of arguments to be passed to the kernel.
              The order should match the argument list on the OpenCL kernel.
              Allowed values are numpy.ndarray, and/or numpy.int32, numpy.float32, and so on.
          :type arguments: list(numpy objects)
  
          :returns: A list of arguments that can be passed to an OpenCL kernel.
          :rtype: list( pyopencl.Buffer, numpy.int32, ... )