0

I have a gray scale images (ultrasound) and i want to train them using CNN and autoencoders but i have issue with number of channels which is 3 by default , when i use the 3 channels an error reported , how can i use only 2 channels.

ValueError: Dimensions must be equal, but are 2 and 3 for 'loss_mse/sub' (op: 'Sub') with input shapes: [?,128,128,2], [?,128,128,3].
icedwater
  • 4,701
  • 3
  • 35
  • 50
  • 1
    you have to modify the network architecture. You could also double a channel and provide the network with redundant information. Of course, this would not work on a pretrained network. What network are you using? Are you using pytorch? tensorflow? Can you provide an example of your network definition ? – kevinkayaks Aug 31 '18 at 21:27
  • I am using tensorflow, which part of code should i modify please? – amr saleh Sep 01 '18 at 20:22

0 Answers0