Can someone help me set up tensorflow & neural-style-tf please?










0














I'm pulling my hair out trying to set up tensorflow and neural-style-tf from github



https://github.com/cysmith/neural-style-tf



keep getting errors after following guides:



https://youtu.be/Rmjp1yFi9Ok?t=2109



and at this point number 6: I am getting errors. ..



'Python 3.6.7 |Anaconda, Inc.| (default, Dec 10 2018, 20:35:02) [MSC v.1915 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
>>> hello = tf.constant('hello!')
>>> sess = tf.session()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: module 'tensorflow' has no attribute 'session'
>>>'


I noticed the python version says (AMD64) on Win32, is this the possible error? (i am intel)



any ideas?



many thanks for any help at all - i'm a competent end user but really in the dark with coding. I am using this for experimental moving image



edit* just wanted to add - i dont want to really touch any coding - i'm a visual artist trying to come up with new forms of moving art. All i want to do is get the neural-style code running on my PC so I can make some images. i managed before with the first public release of deepdream but that took me two days of work.










share|improve this question









New contributor




Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
























    0














    I'm pulling my hair out trying to set up tensorflow and neural-style-tf from github



    https://github.com/cysmith/neural-style-tf



    keep getting errors after following guides:



    https://youtu.be/Rmjp1yFi9Ok?t=2109



    and at this point number 6: I am getting errors. ..



    'Python 3.6.7 |Anaconda, Inc.| (default, Dec 10 2018, 20:35:02) [MSC v.1915 64 bit (AMD64)] on win32
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import tensorflow as tf
    >>> hello = tf.constant('hello!')
    >>> sess = tf.session()
    Traceback (most recent call last):
    File "<stdin>", line 1, in <module>
    AttributeError: module 'tensorflow' has no attribute 'session'
    >>>'


    I noticed the python version says (AMD64) on Win32, is this the possible error? (i am intel)



    any ideas?



    many thanks for any help at all - i'm a competent end user but really in the dark with coding. I am using this for experimental moving image



    edit* just wanted to add - i dont want to really touch any coding - i'm a visual artist trying to come up with new forms of moving art. All i want to do is get the neural-style code running on my PC so I can make some images. i managed before with the first public release of deepdream but that took me two days of work.










    share|improve this question









    New contributor




    Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






















      0












      0








      0







      I'm pulling my hair out trying to set up tensorflow and neural-style-tf from github



      https://github.com/cysmith/neural-style-tf



      keep getting errors after following guides:



      https://youtu.be/Rmjp1yFi9Ok?t=2109



      and at this point number 6: I am getting errors. ..



      'Python 3.6.7 |Anaconda, Inc.| (default, Dec 10 2018, 20:35:02) [MSC v.1915 64 bit (AMD64)] on win32
      Type "help", "copyright", "credits" or "license" for more information.
      >>> import tensorflow as tf
      >>> hello = tf.constant('hello!')
      >>> sess = tf.session()
      Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      AttributeError: module 'tensorflow' has no attribute 'session'
      >>>'


      I noticed the python version says (AMD64) on Win32, is this the possible error? (i am intel)



      any ideas?



      many thanks for any help at all - i'm a competent end user but really in the dark with coding. I am using this for experimental moving image



      edit* just wanted to add - i dont want to really touch any coding - i'm a visual artist trying to come up with new forms of moving art. All i want to do is get the neural-style code running on my PC so I can make some images. i managed before with the first public release of deepdream but that took me two days of work.










      share|improve this question









      New contributor




      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      I'm pulling my hair out trying to set up tensorflow and neural-style-tf from github



      https://github.com/cysmith/neural-style-tf



      keep getting errors after following guides:



      https://youtu.be/Rmjp1yFi9Ok?t=2109



      and at this point number 6: I am getting errors. ..



      'Python 3.6.7 |Anaconda, Inc.| (default, Dec 10 2018, 20:35:02) [MSC v.1915 64 bit (AMD64)] on win32
      Type "help", "copyright", "credits" or "license" for more information.
      >>> import tensorflow as tf
      >>> hello = tf.constant('hello!')
      >>> sess = tf.session()
      Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      AttributeError: module 'tensorflow' has no attribute 'session'
      >>>'


      I noticed the python version says (AMD64) on Win32, is this the possible error? (i am intel)



      any ideas?



      many thanks for any help at all - i'm a competent end user but really in the dark with coding. I am using this for experimental moving image



      edit* just wanted to add - i dont want to really touch any coding - i'm a visual artist trying to come up with new forms of moving art. All i want to do is get the neural-style code running on my PC so I can make some images. i managed before with the first public release of deepdream but that took me two days of work.







      python cuda






      share|improve this question









      New contributor




      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question









      New contributor




      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question








      edited 2 days ago





















      New contributor




      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 2 days ago









      Russell Alderton

      42




      42




      New contributor




      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Russell Alderton is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.




















          1 Answer
          1






          active

          oldest

          votes


















          0














          First you need to add line breaks to your code. Add a line break after your import statement and your code should look like this.



          import tensorflow as tf

          hello = tf.constant('hello!')
          sess = tf.Session()


          Try re-running the code and see what you get. If you still get an error try re-installing tensorflow with the following command. Also, the way your are using constant doesn't really make sense if this is the first line of code in your project. If this is your first time writing code, I recommended getting familiar with the basics first.



          pip3 install --upgrade --force-reinstall tensorflow-gpu


          I am also not sure what you're setting a hello variable. Tensorflow is a pretty advanced library for a beginning programmer. You might want to explore some easier projects for your own sanity. Going straight into tensorflow is like learning calculus before learning to add.



          I also noticed that you have a lowercase session, change the line
          sess = tf.session()



          sess = tf.Session()





          share|improve this answer






















          • pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
            – Russell Alderton
            2 days ago










          • I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
            – Thomas Hayes
            2 days ago











          • i tried that, it seems to work ! many thanks. now I guess on to the next part
            – Russell Alderton
            2 days ago











          • ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
            – Russell Alderton
            2 days ago











          • run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
            – Thomas Hayes
            2 days ago











          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "3"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );






          Russell Alderton is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1388197%2fcan-someone-help-me-set-up-tensorflow-neural-style-tf-please%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0














          First you need to add line breaks to your code. Add a line break after your import statement and your code should look like this.



          import tensorflow as tf

          hello = tf.constant('hello!')
          sess = tf.Session()


          Try re-running the code and see what you get. If you still get an error try re-installing tensorflow with the following command. Also, the way your are using constant doesn't really make sense if this is the first line of code in your project. If this is your first time writing code, I recommended getting familiar with the basics first.



          pip3 install --upgrade --force-reinstall tensorflow-gpu


          I am also not sure what you're setting a hello variable. Tensorflow is a pretty advanced library for a beginning programmer. You might want to explore some easier projects for your own sanity. Going straight into tensorflow is like learning calculus before learning to add.



          I also noticed that you have a lowercase session, change the line
          sess = tf.session()



          sess = tf.Session()





          share|improve this answer






















          • pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
            – Russell Alderton
            2 days ago










          • I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
            – Thomas Hayes
            2 days ago











          • i tried that, it seems to work ! many thanks. now I guess on to the next part
            – Russell Alderton
            2 days ago











          • ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
            – Russell Alderton
            2 days ago











          • run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
            – Thomas Hayes
            2 days ago
















          0














          First you need to add line breaks to your code. Add a line break after your import statement and your code should look like this.



          import tensorflow as tf

          hello = tf.constant('hello!')
          sess = tf.Session()


          Try re-running the code and see what you get. If you still get an error try re-installing tensorflow with the following command. Also, the way your are using constant doesn't really make sense if this is the first line of code in your project. If this is your first time writing code, I recommended getting familiar with the basics first.



          pip3 install --upgrade --force-reinstall tensorflow-gpu


          I am also not sure what you're setting a hello variable. Tensorflow is a pretty advanced library for a beginning programmer. You might want to explore some easier projects for your own sanity. Going straight into tensorflow is like learning calculus before learning to add.



          I also noticed that you have a lowercase session, change the line
          sess = tf.session()



          sess = tf.Session()





          share|improve this answer






















          • pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
            – Russell Alderton
            2 days ago










          • I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
            – Thomas Hayes
            2 days ago











          • i tried that, it seems to work ! many thanks. now I guess on to the next part
            – Russell Alderton
            2 days ago











          • ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
            – Russell Alderton
            2 days ago











          • run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
            – Thomas Hayes
            2 days ago














          0












          0








          0






          First you need to add line breaks to your code. Add a line break after your import statement and your code should look like this.



          import tensorflow as tf

          hello = tf.constant('hello!')
          sess = tf.Session()


          Try re-running the code and see what you get. If you still get an error try re-installing tensorflow with the following command. Also, the way your are using constant doesn't really make sense if this is the first line of code in your project. If this is your first time writing code, I recommended getting familiar with the basics first.



          pip3 install --upgrade --force-reinstall tensorflow-gpu


          I am also not sure what you're setting a hello variable. Tensorflow is a pretty advanced library for a beginning programmer. You might want to explore some easier projects for your own sanity. Going straight into tensorflow is like learning calculus before learning to add.



          I also noticed that you have a lowercase session, change the line
          sess = tf.session()



          sess = tf.Session()





          share|improve this answer














          First you need to add line breaks to your code. Add a line break after your import statement and your code should look like this.



          import tensorflow as tf

          hello = tf.constant('hello!')
          sess = tf.Session()


          Try re-running the code and see what you get. If you still get an error try re-installing tensorflow with the following command. Also, the way your are using constant doesn't really make sense if this is the first line of code in your project. If this is your first time writing code, I recommended getting familiar with the basics first.



          pip3 install --upgrade --force-reinstall tensorflow-gpu


          I am also not sure what you're setting a hello variable. Tensorflow is a pretty advanced library for a beginning programmer. You might want to explore some easier projects for your own sanity. Going straight into tensorflow is like learning calculus before learning to add.



          I also noticed that you have a lowercase session, change the line
          sess = tf.session()



          sess = tf.Session()






          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited 2 days ago

























          answered 2 days ago









          Thomas Hayes

          295




          295











          • pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
            – Russell Alderton
            2 days ago










          • I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
            – Thomas Hayes
            2 days ago











          • i tried that, it seems to work ! many thanks. now I guess on to the next part
            – Russell Alderton
            2 days ago











          • ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
            – Russell Alderton
            2 days ago











          • run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
            – Thomas Hayes
            2 days ago

















          • pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
            – Russell Alderton
            2 days ago










          • I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
            – Thomas Hayes
            2 days ago











          • i tried that, it seems to work ! many thanks. now I guess on to the next part
            – Russell Alderton
            2 days ago











          • ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
            – Russell Alderton
            2 days ago











          • run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
            – Thomas Hayes
            2 days ago
















          pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
          – Russell Alderton
          2 days ago




          pip3 install --upgrade --force-reinstall tensorflow-gpu I get 'invalid syntax' . this is in anaconda prompt.
          – Russell Alderton
          2 days ago












          I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
          – Thomas Hayes
          2 days ago





          I just noticed in your code you have a lowercase session change the line look at my updated answer and run the code again.
          – Thomas Hayes
          2 days ago













          i tried that, it seems to work ! many thanks. now I guess on to the next part
          – Russell Alderton
          2 days ago





          i tried that, it seems to work ! many thanks. now I guess on to the next part
          – Russell Alderton
          2 days ago













          ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
          – Russell Alderton
          2 days ago





          ok, the last part is to install keras apparently? I installed git and tried via the git clone github.com/keras-team/keras.git command and got this error: File "<stdin>", line 1 git clone github.com/keras-team/keras.git ^ SyntaxError: invalid syntax I apologise for the unclean writing i'm not used to forums where enter doesnt make a line break!
          – Russell Alderton
          2 days ago













          run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
          – Thomas Hayes
          2 days ago





          run the following command in the terminal pip3 install Keras , to get to this on windows type in cmd in the search bar and run it through there
          – Thomas Hayes
          2 days ago











          Russell Alderton is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          Russell Alderton is a new contributor. Be nice, and check out our Code of Conduct.












          Russell Alderton is a new contributor. Be nice, and check out our Code of Conduct.











          Russell Alderton is a new contributor. Be nice, and check out our Code of Conduct.














          Thanks for contributing an answer to Super User!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid …


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.





          Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


          Please pay close attention to the following guidance:


          • Please be sure to answer the question. Provide details and share your research!

          But avoid …


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1388197%2fcan-someone-help-me-set-up-tensorflow-neural-style-tf-please%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Top Tejano songwriter Luis Silva dead of heart attack at 64

          政党

          天津地下鉄3号線