Intel® DevCloud
Help for those needing help starting or connecting to the Intel® DevCloud
Announcements
The Intel sign-in experience is changing in February to support enhanced security controls. If you sign in, click here for more information.
1218 Discussions

Cannot install pandas

BartPigula
Beginner
362 Views

Hello,

I need to run a python script that requires pandas, but python3 on my node can't find it. I was trying to install it with 

pip3 install pandas --user

but pip is not found as well - i get the following output:

BartPigula_0-1671608561719.png

I've also tried creating env with conda but it failed:

BartPigula_1-1671608648612.png

How can i install pandas so i can run my script for example from jupyter cell magic

!python3 script.py

??

Regards,

Bartek

0 Kudos
1 Solution
DiyaN_Intel
Moderator
312 Views

Hi,       

 

Please follow the steps I've included below to add a new environment to the jupyter notebook.

                                      

1. To create an environment -

 

conda create -n <env_name>

 

2. Activate the new environment

 

conda activate <env_name>

 

3. Install ipykernel

 

 conda install ipykernel

 

4. Install pandas 

 

  pip3 install pandas

 

5. Can view the existing environment list 

 

conda env list

 

6. Add the new kernel in jupyter notebook

 

 ipython kernel install --name <env_name> --user

 

7. Open the jupyter lab and set the kernel to this environment

 

 Kernel --> change kernel --> select the one you want

 

 

This will help you to use the environment that you created in the terminal in jupyter notebook.                          

If you face any issues please connect back to us.

If this resolves your issue, make sure to accept this as a solution. This would help others with similar issue. Thank you!

 

Regards,

Diya 

 

 

View solution in original post

4 Replies
DiyaN_Intel
Moderator
345 Views

Hi ,

 

Thank you for posting in Intel communities.

Could you please try setting up oneAPI environment variables forcefully and check once again if it is running properly or not.

Please run the below command:

source /opt/intel/oneapi/setvars.sh --force

If you face any issues please connect back to us. 

If this resolves your issue, make sure to accept this as a solution. This would help others with similar issue. Thank you!

 

Regards, 

Diya 

 

BartPigula
Beginner
321 Views

Thanks for the reply,

I did what you suggested and it kind of partially worked: from terminal i was able to run pip3 install pandas --user and the script works good when ran from terminal, but as i try to run the same script but from notebook with command:

!python3 check_finished.py

i still get the message 

BartPigula_0-1671697872087.png

 

DiyaN_Intel
Moderator
313 Views

Hi,       

 

Please follow the steps I've included below to add a new environment to the jupyter notebook.

                                      

1. To create an environment -

 

conda create -n <env_name>

 

2. Activate the new environment

 

conda activate <env_name>

 

3. Install ipykernel

 

 conda install ipykernel

 

4. Install pandas 

 

  pip3 install pandas

 

5. Can view the existing environment list 

 

conda env list

 

6. Add the new kernel in jupyter notebook

 

 ipython kernel install --name <env_name> --user

 

7. Open the jupyter lab and set the kernel to this environment

 

 Kernel --> change kernel --> select the one you want

 

 

This will help you to use the environment that you created in the terminal in jupyter notebook.                          

If you face any issues please connect back to us.

If this resolves your issue, make sure to accept this as a solution. This would help others with similar issue. Thank you!

 

Regards,

Diya 

 

 

DiyaN_Intel
Moderator
296 Views

Hi ,


Glad to know that your issue is resolved. If you need any additional information, please post a new question as this thread will no longer be monitored by Intel.


Regards,

Diya


Reply