Exemplo n.º 1
0
 def addRenderPartition(self, host, threads, cores, memory, gpu):
     self.stub.AddRenderPartition(
         job_pb2.FrameAddRenderPartitionRequest(frame=self.data,
                                                host=host,
                                                threads=threads,
                                                max_cores=cores,
                                                max_memory=memory,
                                                max_gpu=gpu,
                                                username=os.getenv(
                                                    "USER", "unknown")))
Exemplo n.º 2
0
 def addRenderPartition(self, hostname, threads, max_cores, num_mem, max_gpu):
     """Add a render partition to the frame.
     @type  hostname: str
     @param hostname: hostname of the partition
     @type  threads: int
     @param threads: number of threads of the partition
     @type  max_cores: int
     @param max_cores: max cores enabled for the partition
     @type  num_mem: int
     @param num_mem: amount of memory reserved for the partition
     @type  max_gpu: int
     @param max_gpu: max gpu cores enabled for the partition
     """
     response = self.stub.AddRenderPartition(
         job_pb2.FrameAddRenderPartitionRequest(frame=self.data,
                                                host=hostname,
                                                threads=threads,
                                                max_cores=max_cores,
                                                max_memory=num_mem,
                                                max_gpu=max_gpu,
                                                username=os.getenv("USER", "unknown")))