PhotographicImageSynthesis icon indicating copy to clipboard operation
PhotographicImageSynthesis copied to clipboard

two questions about the code

Open icoz69 opened this issue 8 years ago • 1 comments

thanks for the code. its a cool implementation. i have two questions about the code 1. the first is about the 'computer_error' functions. for exmale,the size of fake and real are NHWC, after expand_dims(tf.reduce_mean(tf.abs(fake-real),reduction_indices=[3]),-1) ,the size is NHW1 then the result label returns NHW20,and the final result of this function is N*20,right?

2.the second question is label:np.concatenate((label_images[ind],np.expand_dims(1-np.sum(label_images[ind],axis=3),axis=3)),axis=3) why the 19-dimention label maps are concatenated with np.expand_dims(1-np.sum(label_images[ind],axis=3),axis=3)). i guess the later parts refers to some transformation error between RGB label images and 19-dimention labels.

thanks

icoz69 avatar Sep 19 '17 08:09 icoz69

  1. That's correct.

  2. I expand a 19D label map to 20D. The expanded extra dimension is for "void" regions. This ensures that each pixel has a one-hot-vector at each pixel. This prevents the network performing convolutions with a tensor with all zeros.

CQFIO avatar Sep 19 '17 16:09 CQFIO