(self, input)
| 96 | self._loss_d_gp = Variable(self._Tensor([0])) |
| 97 | |
| 98 | def set_input(self, input): |
| 99 | self._input_real_img.resize_(input['real_img'].size()).copy_(input['real_img']) |
| 100 | self._input_real_cond.resize_(input['real_cond'].size()).copy_(input['real_cond']) |
| 101 | self._input_desired_cond.resize_(input['desired_cond'].size()).copy_(input['desired_cond']) |
| 102 | self._input_real_id = input['sample_id'] |
| 103 | self._input_real_img_path = input['real_img_path'] |
| 104 | |
| 105 | if len(self._gpu_ids) > 0: |
| 106 | self._input_real_img = self._input_real_img.cuda(self._gpu_ids[0], async=True) |
| 107 | self._input_real_cond = self._input_real_cond.cuda(self._gpu_ids[0], async=True) |
| 108 | self._input_desired_cond = self._input_desired_cond.cuda(self._gpu_ids[0], async=True) |
| 109 | |
| 110 | def set_train(self): |
| 111 | self._G.train() |
nothing calls this directly
no outgoing calls
no test coverage detected