Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dependency for ipykernel #10

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Add dependency for ipykernel #10

wants to merge 1 commit into from

Conversation

emptymalei
Copy link
Member

@emptymalei emptymalei commented Feb 25, 2023

ipykernel is required to create a new jupyter kernel.

Install dependencies

poetry install --with lab

Then

poetry run ipython kernel install --user --name=ts-diffusion-kernel

@cmp0xff cmp0xff added the enhancement New feature or request label Feb 26, 2023
@cmp0xff
Copy link
Contributor

cmp0xff commented Feb 26, 2023

Steps:

  1. (Since I have already installed jupyterlab with conda in the ts-diffusion environment,) remove the conda environment ts-diffusion by conda env remove -n ts-diffusion
  2. Install the environment following https://github.com/orgs/neuronstar/projects/2?pane=issue&itemId=19113095
    2.1. python==3.10.* is needed, otherwise no compatible torch version can be found.
    2.1. poetry and pre-commit install by brew
  3. It turns out that poetry install already installs ipykernel, jupyter-core etc. Is this expected?

@emptymalei emptymalei self-assigned this Feb 26, 2023
@emptymalei
Copy link
Member Author

3 -> looks like ipykernel is already required by one of the existing packages.

I guess we just close this PR.

@cmp0xff
Copy link
Contributor

cmp0xff commented Feb 26, 2023

3 -> looks like ipykernel is already required by one of the existing packages.

I guess we just close this PR.

I still need the package jupyterlab. Is it required by any other packages?

@emptymalei
Copy link
Member Author

emptymalei commented Feb 26, 2023

jupyterlab should be installed outside of the project, e.g., some jupyterlab env.

After poetry run ipython kernel install --user --name=ts-diffusion-kernel, jupyterlab will see the kernel ts-diffusion-kernel.

Screenshot 2023-02-26 at 20 48 02

Screenshot 2023-02-26 at 20 47 40

@cmp0xff
Copy link
Contributor

cmp0xff commented Feb 26, 2023

Okay. What would be the process if I want to go back to main? Do I need to remove the conda environment and reinstall again?

@emptymalei
Copy link
Member Author

My guess is poetry install --sync

https://python-poetry.org/docs/cli/#options-2

@cmp0xff
Copy link
Contributor

cmp0xff commented Feb 26, 2023

• Updating watchdog (2.3.0 -> 2.2.1): Failed

Guess I have to uninstall the conda env...

BTW, the main branch does not contain ipython as a requirement.

@cmp0xff
Copy link
Contributor

cmp0xff commented Feb 26, 2023

poetry run ipython kernel install --user --name=ts-diffusion-kernel

It does not work with the requirements in the main branch.

@emptymalei
Copy link
Member Author

emptymalei commented Feb 26, 2023

poetry run ipython kernel install --user --name=ts-diffusion-kernel

It does not work with the requirements in the main branch.

works for me

Screenshot 2023-02-26 at 21 42 40

Is it a conda poetry compatibility problem? I am using virtualenv.
Screenshot 2023-02-26 at 21 45 21

I can test on conda later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants