Hey guys, I am trying to run OpenMC using Python on a Windows machine, and I am completely stumped after 2 days of trying. I am looking for guidance.
I have Docker installed, and following the install instructions (Quick Install Guide — OpenMC Documentation), I paste docker run openmc/openmc:latest into powershell. The first time I did this, it took some time to download. The install guide says that this should “place you in an interactive shell running in a Docker container with OpenMC installed”. Normally when I use Python, I use Anaconda’s Spyder to write a script, and I run it using cmd or Anaconda powershell. So could someone tell me what an “interactive shell running in a docker container” should look like? Now when I run that command, it just puts me on a new command line. If I try to run a Python script from this powershell, the import openmc line in my script will throw an error. If someone could tell me how exactly I should be using Docker to run OpenMC with Python, that would be immensely helpful. Alternatively, is there any way to run it on a windows machine without docker?
Thank you for your time – and let me know if I can clarify anything. Looking forward to learning the material.
As an update, using the developer’s guide, I think I have an openmc container running in my shell, but when I try to run my python script, it can’t find my file. How do I run my Python script through the Docker container?
In addition to the other discussion on this (Deployment with Docker?), I’d mention that Docker is not the only way to run on Windows. You can also use the Windows subsystem for linux as described here, but for your purposes, Docker may be an easier solution since you don’t need to figure out how to get it compiled in the first place.
I’m experiencing some of these same issues. I finally figured out how to get it to work in Linux using Ubuntu (kinda), but windows seems to have a high barrier to entry for OpenMC on Windows. Are there any updates on Windows compatibility with OpenMC since the last comment on this thread?