GithubHelp home page GithubHelp logo

How to predict ? about srcnn-tensorflow HOT 6 CLOSED

tegg89 avatar tegg89 commented on September 26, 2024
How to predict ?

from srcnn-tensorflow.

Comments (6)

tegg89 avatar tegg89 commented on September 26, 2024

@kitterive Thanks for left comments.
The loss issue has not solved yet. I am still working on this matter, but super-resolution works.
To test model, you have to make stride option like --stride 21, which is same size as label size. I forgot to put it in readme file. Sorry.

from srcnn-tensorflow.

kitterive avatar kitterive commented on September 26, 2024

Hi tegg89,
Thanks your reply! I tested use the command "python main.py --is_train False --stride 21", I found nothing output, just display " [*] Reading checkpoints...", and sample directory is also empty.
What I mean is: if I have a size 1920X1080 test.bmp, I will want to use it to verify the model is correct, I will downsampe the bmp, then upsample it to size 1920x1080, generate the low resolution bmp as the input of this model, the outut is the super resolution result. how to do it?
I also run "liliumao/Tensorflow-srcnn" "predict.py" file use his model, I found the output.bmp is wrong.

from srcnn-tensorflow.

kitterive avatar kitterive commented on September 26, 2024

I reference "liliumao/Tensorflow-srcnn" srcnn.py code, and test your code as such, it can decrease loss, but I'm a tensorflow beginner, I don't know why it is.
train_op = tf.train.GradientDescentOptimizer(config.learning_rate).minimize(self.loss,global_step=self.global_step)

_,step = self.sess.run([train_op, self.global_step], feed_dict={self.images:batch_images, self.labels:batch_labels})

    err = self.sess.run(self.loss, feed_dict={self.images:batch_images, self.labels:batch_labels})
   
    print("Epoch: [%2d] [%4d/%4d], step: [%2d], time: [%4.4f], loss: [%.8f]" \
          % (ep, idx, batch_idxs, counter, time.time()-start_time, err))

from srcnn-tensorflow.

tegg89 avatar tegg89 commented on September 26, 2024

@kitterive Thanks for replies. I am currently working on loading model, but the loss value and preprocessing still keep wrong. As soon as figuring these out, I will upload new files. Thanks :)

from srcnn-tensorflow.

tegg89 avatar tegg89 commented on September 26, 2024

@kitterive I changed sources. You can train and test files following the readme file. I will close this issue, and if you have any problem, feel free to raise. Thanks :)

from srcnn-tensorflow.

niuniu111 avatar niuniu111 commented on September 26, 2024

The result of operation is grayscale, can't it be color chart?

from srcnn-tensorflow.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.