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

Colab #1

Open
LucasSilvaFerreira opened this issue Dec 2, 2022 · 13 comments
Open

Colab #1

LucasSilvaFerreira opened this issue Dec 2, 2022 · 13 comments

Comments

@LucasSilvaFerreira
Copy link

LucasSilvaFerreira commented Dec 2, 2022

Hi. Is it possible to run this code in the colab pro?
Are you guys about to release some colab? Very nice work.

@w-hc
Copy link
Contributor

w-hc commented Dec 2, 2022

We will. This uses < 9GB of GPU memory, and should be ok with regular colab.

@dvschultz
Copy link

I put one together here: https://colab.research.google.com/drive/1zixo66UYGl70VOPy053o7IV_YkQt5lCZ?usp=sharing

@w-hc
Copy link
Contributor

w-hc commented Dec 2, 2022

wow thank you!

@elloza
Copy link

elloza commented Dec 3, 2022

I put one together here: https://colab.research.google.com/drive/1zixo66UYGl70VOPy053o7IV_YkQt5lCZ?usp=sharing

is it working rigth now?

, line 34, in load_model_from_config
pl_sd = torch.load(ckpt, map_location="cpu")
File "/usr/local/lib/python3.8/dist-packages/torch/serialization.py", line 712, in load
return _load(opened_zipfile, map_location, pickle_module, **pickle_load_args)
File "/usr/local/lib/python3.8/dist-packages/torch/serialization.py", line 1049, in _load
result = unpickler.load()
File "/usr/local/lib/python3.8/dist-packages/torch/serialization.py", line 1042, in find_class
return super().find_class(mod_name, name)
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/init.py", line 20, in
from pytorch_lightning import metrics # noqa: E402
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/metrics/init.py", line 15, in
from pytorch_lightning.metrics.classification import ( # noqa: F401
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/metrics/classification/init.py", line 14, in
from pytorch_lightning.metrics.classification.accuracy import Accuracy # noqa: F401
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/metrics/classification/accuracy.py", line 18, in
from pytorch_lightning.metrics.utils import deprecated_metrics, void
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/metrics/utils.py", line 29, in
from pytorch_lightning.utilities import rank_zero_deprecation
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/utilities/init.py", line 18, in
from pytorch_lightning.utilities.apply_func import move_data_to_device # noqa: F401
File "/usr/local/lib/python3.8/dist-packages/pytorch_lightning/utilities/apply_func.py", line 31, in
from torchtext.legacy.data import Batch
ModuleNotFoundError: No module named 'torchtext.legacy'

@elloza
Copy link

elloza commented Dec 3, 2022

I think I found the issue:

TLDR;
!pip install pytorch-lightning==1.8.3.post0

Ref: Stability-AI/stablediffusion#8

Congratulations for the work by the way!

@paracanthurus25
Copy link

I put one together here: https://colab.research.google.com/drive/1zixo66UYGl70VOPy053o7IV_YkQt5lCZ?usp=sharing

So I keep getting this error when I run the "Download Assets" cell:

tar: /content/sjc/release.tar: Cannot open: No such file or directory
tar: Error is not recoverable: exiting now

If I try to run the next cell, "update env.json," then I get this error:

FileNotFoundError: [Errno 2] No such file or directory: '/content/drive/MyDrive/sjc/env.json'

Any help would be greatly appreciated :)

@LucasSilvaFerreira
Copy link
Author

LucasSilvaFerreira commented Dec 14, 2022 via email

@LucasSilvaFerreira
Copy link
Author

I tried it using my notebook. But the final version 3d model is pretty pixelated. I don't know if this colab is taking advantage of the unpixelated improvement. @w-hc

@paracanthurus25
Copy link

Thanks. It still gives the error in the "Download Assets" cell, but it allows me to run the other cells. In the second cell under "Run Experiments," it gives me this error:

FileNotFoundError: [Errno 2] No such file or directory: '/content/gdrive/MyDrive/sjc/release/diffusion_ckpts/stable_diffusion/sd-v1-5.ckpt.

I looked in my Google Drive and I couldn't find the release directory.

@LucasSilvaFerreira
Copy link
Author

It seems that you are mounting the drive with another name ('gdrive' or 'drive'). Make sure the drive you mounted has the same name of the required directories.

@LucasSilvaFerreira
Copy link
Author

Check if the current version is saving the SD model in this in same directory. Maybe they changed and I'm using the old directory reference

@w-hc
Copy link
Contributor

w-hc commented Dec 14, 2022

@LucasSilvaFerreira no the colab is not using the subpix rendering. we will update the colab.

@paracanthurus25
Copy link

So I actually got the original colab to work all the way until the second cell under the "run experiments" module, where it gives me this error:

ModuleNotFoundError: No module named 'taming'

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

No branches or pull requests

5 participants