How to use pip and install python package

Hi everyone,

I’m don’t understand in the screenshot here where I should type the line “pip install”, I have the image debian/openmc:latest and the interactive shell running, I thought I should run pip install in it but it doesn’t work. I also have python installed. Thank you for your help.

Thanks the question.

The docker images should already have had the pip install . command run when they were built.

But if you want to rerun it then perhaps try navigating to the root repository folder. Which is found at /root/OpenMC/openmc

Screenshot from 2022-09-26 12-36-32

Thank you so much for your help. Yes I have docker and I have the shell to use open MC, how can I get jupyter notebook to run blocks of code?

This is what I get when I use powershell:

When in Jupyter to run a code block in Jupyter you can click the run button which looks like a triangle or press shift and enter when on the code block.

To get Juypter into the OpenMC docker you might want to extend the dockerfile to include Jupyter.

Here is a video that might help
Adding Jupyter Lab to the OpenMC Docker image. - YouTube

I tried doing everything in the video and everything worked until the code Dockerfile line, I used powershel and cmd to run it but I got an error shown in the screenshot, how can I create a docker file like the one in the video?

Oh yes sorry I should have mentioned. Code is visual studio code. It is however just used as a text editor, so you can use any text editor to make the Dockerfile. It might be easiest to open notepad from the start menu to create the Dockerfile

Got it thank you so much for your help!