Closed Chee-Foong closed 3 years ago
def get_global_histogram(img_path): ref_img_fullres = caffe.io.load_image(ref_path) img_glob_dist = (255*caffe.io.resize_image(ref_img_fullres,(Xd,Xd))).astype('uint8') # load image gt_glob_net.blobs['img_bgr'].data[...] = img_glob_dist[:,:,::-1].transpose((2,0,1)) # put into gt_glob_net.forward(); glob_dist_in = gt_glob_net.blobs['gt_glob_ab_313_drop'].data[0,:-1,0,0].copy() return (glob_dist_in,ref_img_fullres)
ref_img_fullres = caffe.io.load_image(ref_path)
should be
ref_img_fullres = caffe.io.load_image(img_path)
?
It was fixed by the latest commit.
ref_img_fullres = caffe.io.load_image(ref_path)
should be
ref_img_fullres = caffe.io.load_image(img_path)
?