A tensorflow implementation of "Fast and Accurate Image Super Resolution by Deep CNN with Skip Connection and Network in Network", a deep learning based Single-Image Super-Resolution (SISR) model.
I am working on using this model to super resolution every single frame of a video.
I created a "do_frame" function similar to "do" and this function only took one argument as the image. Right now, I print out the shape of the frame after entering this "do_frame" function. The shape is (720, 1280, 3), but then an error occurs:
ValueError: Cannot feed value of shape (1, 720, 1280, 3) for Tensor 'x:0', which has shape '(?, ?, ?, 1)'.
The image has been reshaped by the moment of sending it to self.sess.run. I don't understand why this generates an error, but it works for images.
The error occurs here:
y = self.sess.run(self.y_, feed_dict={self.x: image.reshape(1, image.shape[0], image.shape[1], ch),self.x2: bicubic_image.reshape(1,self.scale * image.shape[0],self.scale * image.shape[1],ch),self.dropout: 1.0, self.is_training: 0})
Hi, this is because the model only accepts monochrome image.
When it gets a 3 channel RGB color image as an input, it coverts into YCbCr image and apply only Y channel.
I am working on using this model to super resolution every single frame of a video. I created a "do_frame" function similar to "do" and this function only took one argument as the image. Right now, I print out the shape of the frame after entering this "do_frame" function. The shape is (720, 1280, 3), but then an error occurs: ValueError: Cannot feed value of shape (1, 720, 1280, 3) for Tensor 'x:0', which has shape '(?, ?, ?, 1)'. The image has been reshaped by the moment of sending it to self.sess.run. I don't understand why this generates an error, but it works for images.
The error occurs here:
y = self.sess.run(self.y_, feed_dict={self.x: image.reshape(1, image.shape[0], image.shape[1], ch),self.x2: bicubic_image.reshape(1,self.scale * image.shape[0],self.scale * image.shape[1],ch),self.dropout: 1.0, self.is_training: 0})