Error with python generate.py -p command after updating to the latest version of Anaconda
Redivh opened this issue · 3 comments
Redivh commented
The python generate.py -p command gave me this error after I upgraded to the latest version of Anaconda 2022.05.
I was able to get it to work again without the error after I downgraded to Anaconda version 2021.11.
Is it possible for this to work with Anaconda version 2022.05?
File "C:\Users\Computer\VQGAN-CLIP\generate.py", line 18, in <module>
from taming.models import cond_transformer, vqgan
File "C:\Users\Computer\VQGAN-CLIP\taming-transformers\taming\models\cond_transformer.py", line 4, in <module>
import pytorch_lightning as pl
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\__init__.py", line 30, in <module>
from pytorch_lightning.callbacks import Callback # noqa: E402
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\callbacks\__init__.py", line 26, in <module>
from pytorch_lightning.callbacks.pruning import ModelPruning
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\callbacks\pruning.py", line 31, in <module>
from pytorch_lightning.core.lightning import LightningModule
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\core\__init__.py", line 16, in <module>
from pytorch_lightning.core.lightning import LightningModule
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\core\lightning.py", line 40, in <module>
from pytorch_lightning.loggers import LightningLoggerBase, LoggerCollection
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\loggers\__init__.py", line 18, in <module>
from pytorch_lightning.loggers.tensorboard import TensorBoardLogger
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\pytorch_lightning\loggers\tensorboard.py", line 26, in <module>
from torch.utils.tensorboard import SummaryWriter
File "C:\Users\Computer\anaconda3\envs\vqgan\lib\site-packages\torch\utils\tensorboard\__init__.py", line 4, in <module>
LooseVersion = distutils.version.LooseVersion
AttributeError: module 'distutils' has no attribute 'version'```
thelittlemike commented
I had this same problem and fixed it by just downgrading setuptools to version 59.5.0
nerdyrodent commented
Glad you got it sorted ;)
BeaverInGreenland commented
I had this same problem and fixed it by just downgrading setuptools to version 59.5.0
Thanks for solving this issue !