'Using TensorFlow in IDE on Windows

I have used the Docker installation as suggested at https://bishnusarker.wordpress.com/2015/11/11/how-to-install-google-tensorflow-in-your-windows-machine-using-docker-image/ to run TensorFlow on my Windows 7 machine. I have it up and running on the docker terminal. I would like to know how to import the TensorFlow library from the PyCharm IDE.



Solution 1:[1]

Since I am currently struggling with a similar issue, I came across your question. You can run PyCharm on your Windows machine and configure a remote interpreter to mount your python code to the docker image, in which your libraries reside and run it there as described here: https://blog.jetbrains.com/pycharm/2015/12/using-docker-in-pycharm/ For tensorflow in particular, this might be interesting as well: http://killianlevacher.github.io/blog/posts/post-2016-07-22/post.html

Solution 2:[2]

There is no way to make it work. Your tensorflow installation is inside the docker container, while PyCharm running on Windows searches for your available Python libraries in Windows; it has no access to docker.

You could, instead, try to install and run PyCharm in docker as well (I'm not sure if it is viable though).

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 molig
Solution 2 erickrf