Intel® DevCloud
Help for those needing help starting or connecting to the Intel® DevCloud
1638 Discussions

new kernel connecting failure

Liu__Yuhan
Beginner
1,043 Views

I created a new kernel with my own enviroment

But it still using the glob enviroment

I open the kernel.json file of my kernel

{
 "argv": [
  "/glob/intel-python/versions/2018u2/intelpython3/bin/python",
  "-m",
  "ipykernel_launcher",
  "-f",
  "{connection_file}"
 ],
 "display_name": "lyhpy36_2",
 "language": "python"
}

 

Here in "argv" it still use the python of "/glob" instead of "/uxxxxx/.conda/envs/xxxx"

So I changed "/glob/intel-python/versions/2018u2/intelpython3/bin/python", to "/uxxxxx/.conda/envs/xxxxxxxxx/xxxxxx"

And then my kernel has connecting failure. 

I wonder why and how can I use my kernel with my own enviroment instead of the global one.

0 Kudos
9 Replies
Liu__Yuhan
Beginner
1,043 Views

By the way,  I already "source activate my_env" before I create the new kernel

0 Kudos
AthiraM_Intel
Moderator
1,043 Views

Hi,

Thanks for reaching out to us.

We understand your concern. Could you please verify whether you face the same issue with a newly created environment.

Please follow the below steps.

1. Create a new environment

conda create --name <env_name>

2. Activate the new environment

source activate <env_name>

3. To add new kernel

ipython kernel install --name "env_name" --user 

4. Open jupyter terminal  and give

cd /home/u*****/.local/share/jupyter/kernels/<env_name>

5. Open kernel.json and check if the python path referenced is /glob python or path to your <env_name>. If it is /glob python, change the path to

/home/u*****/.conda/envs/<env_name>/bin/python

6. Open the terminal and activate new environment.

source activate <env_name>

7. Check the path of Python by giving the following command: which python. If it references /glob python path, update the PATH by exporting the conda python path.

export PATH="/home/u*****/.conda/envs/<env_name>/bin":$PATH

8. On checking which python, it should show the updated python PATH.

 

Please verify and let us know if the solution provided worked. If the issue still persists, share the steps you have followed with the corresponding screenshots.  

 

Thanks

 

 

 

 

0 Kudos
AthiraM_Intel
Moderator
1,043 Views

Hi,

Could you please confirm whether your issue got resolved?

0 Kudos
Liu__Yuhan
Beginner
1,043 Views

AthiraM_Intel (Intel) wrote:

Hi,

Thanks for reaching out to us.

We understand your concern. Could you please verify whether you face the same issue with a newly created environment.

Please follow the below steps.

1. Create a new environment

conda create --name <env_name>

2. Activate the new environment

source activate <env_name>

3. To add new kernel

ipython kernel install --name "env_name" --user 

4. Open jupyter terminal  and give

cd /home/u*****/.local/share/jupyter/kernels/<env_name>

5. Open kernel.json and check if the python path referenced is /glob python or path to your <env_name>. If it is /glob python, change the path to

/home/u*****/.conda/envs/<env_name>/bin/python

6. Open the terminal and activate new environment.

source activate <env_name>

7. Check the path of Python by giving the following command: which python. If it references /glob python path, update the PATH by exporting the conda python path.

export PATH="/home/u*****/.conda/envs/<env_name>/bin":$PATH

8. On checking which python, it should show the updated python PATH.

 

Please verify and let us know if the solution provided worked. If the issue still persists, share the steps you have followed with the corresponding screenshots.  

 

Thanks

 

 

 

 

 

I have done it according to the direction you gave me. 

But I cannot connect to the kernel and got this all the time until the connection fails.

It said "Kernel starting please wait" 

0 Kudos
Liu__Yuhan
Beginner
1,043 Views

AthiraM_Intel (Intel) wrote:

Hi,

Thanks for reaching out to us.

We understand your concern. Could you please verify whether you face the same issue with a newly created environment.

Please follow the below steps.

1. Create a new environment

conda create --name <env_name>

2. Activate the new environment

source activate <env_name>

3. To add new kernel

ipython kernel install --name "env_name" --user 

4. Open jupyter terminal  and give

cd /home/u*****/.local/share/jupyter/kernels/<env_name>

5. Open kernel.json and check if the python path referenced is /glob python or path to your <env_name>. If it is /glob python, change the path to

/home/u*****/.conda/envs/<env_name>/bin/python

6. Open the terminal and activate new environment.

source activate <env_name>

7. Check the path of Python by giving the following command: which python. If it references /glob python path, update the PATH by exporting the conda python path.

export PATH="/home/u*****/.conda/envs/<env_name>/bin":$PATH

8. On checking which python, it should show the updated python PATH.

 

Please verify and let us know if the solution provided worked. If the issue still persists, share the steps you have followed with the corresponding screenshots.  

 

Thanks

 

 

 

 

 

I have done it according to the direction you gave me. 

But I cannot connect to the kernel and got this all the time until the connection fails.

It said "Kernel starting please wait" 

0 Kudos
AthiraM_Intel
Moderator
1,043 Views

Hi,

We understand your concern. We have informed the concerned admin team regarding your issue.

Thanks

0 Kudos
AthiraM_Intel
Moderator
1,043 Views

Hi,

Could you please check if the issue exists. If it still persists, we will create a new account for you. 

 Thanks

0 Kudos
JananiC_Intel
Moderator
1,043 Views

Hi,

Could you please give us an update?

0 Kudos
AthiraM_Intel
Moderator
1,043 Views

Hi,

Hope your issue got resolved. We are closing this thread. Please feel free to open a new thread if you have any further queries.

Thanks

0 Kudos
Reply