def __init__(self):
dict_ = cPickle.load(open(file_path + '/dict_.pkl', "rb"))
gen_images = dict_['gen_images']
self.num_ex = 4
self.row_list = []
if 'ground_truth' in dict_:
ground_truth = dict_['ground_truth']
if not isinstance(ground_truth, list):
ground_truth = np.split(ground_truth, ground_truth.shape[1], axis=1)
ground_truth = [np.squeeze(g) for g in ground_truth]
ground_truth = ground_truth[1:]
self.row_list.append((ground_truth, 'Ground Truth'))
self.row_list.append((gen_images, 'Gen Images'))
self.build_figure()
评论列表
文章目录