Closed tim-andes closed 2 years ago
Hi, I had the same error and this solution works for me. https://github.com/python/typing/issues/707 I'm sure it's not the best solution so... If someone knows something better please help us.
Thanks for the report. The issue was in a dependency, and has been fixed upstream (https://github.com/CompVis/taming-transformers/commit/37afdf35f0bdd30a8b95ebc9a4fc4bd6bc1e8c03) - if you restart and try again, it should work now.
Hi, so it is getting quite difficult to find the solution for the error.
The code is not installing the taming models
below is the error code and then the source code -
ModuleNotFoundError Traceback (most recent call last)
[<ipython-input-12-c026441db553>](https://localhost:8080/#) in <cell line: 13>()
11 from omegaconf import OmegaConf
12 from PIL import Image
---> 13 from taming.models import cond_transformer, vqgan
14 import torch
15 from torch import nn, optim
2 frames
[/content/./taming-transformers/taming/data/utils.py](https://localhost:8080/#) in <module>
9 import torch
10 from taming.data.helper_types import Annotation
---> 11 from torch._six import string_classes
12 from torch.utils.data._utils.collate import np_str_obj_array_pattern, default_collate_err_msg_format
13 from tqdm import tqdm
ModuleNotFoundError: No module named 'torch._six'
---------------------------------------------------------------------------
NOTE: If your import is failing due to a missing package, you can
manually install dependencies using either !pip or !apt.
To view examples of installing some common dependencies, click the
"Open Examples" button below.
import argparse
import math
from pathlib import Path
import sys
sys.path.append('./taming-transformers')
from IPython import display
from base64 import b64encode
from omegaconf import OmegaConf
from PIL import Image
from taming.models import cond_transformer, vqgan
import torch
from torch import nn, optim
from torch.nn import functional as F
from torchvision import transforms
from torchvision.transforms import functional as TF
from tqdm.notebook import tqdm
from CLIP import clip
import kornia.augmentation as K
import numpy as np
import imageio
from PIL import ImageFile, Image
from imgtag import ImgTag # metadatos
from libxmp import * # metadatos
import libxmp # metadatos
from stegano import lsb
import json
ImageFile.LOAD_TRUNCATED_IMAGES = True```
Describe the bug
Parameters used Did not get to parameters
Which cell you saw the error in "# @title Loading of libraries and definitions"
Error message See above