mfrashad / text2art

AI-powered Text-to-Art Generator - Text2Art.com
Other
778 stars 208 forks source link

clipit fails to import #2

Closed szymekdr closed 2 years ago

szymekdr commented 2 years ago

Hi, trying to run this from Google Colab, returns this error:

ImportError                               Traceback (most recent call last)
<ipython-input-17-25d790141602> in <module>()
----> 1 import clipit
      2 # To reset settings to default
      3 clipit.reset_settings()
      4 # You can use "|" to separate multiple prompts
      5 prompts = "underwater city"

/content/clipit/clipit.py in <module>()
     22 #torch.use_deterministic_algorithms(True)               # NR: grid_sampler_2d_backward_cuda does not have a deterministic implementation
     23 
---> 24 from torch_optimizer import DiffGrad, AdamP, RAdam
     25 from perlin_numpy import generate_fractal_noise_2d
     26 

ImportError: cannot import name 'RAdam' from 'torch_optimizer' (/usr/local/lib/python3.7/dist-packages/torch_optimizer/__init__.py)
mfrashad commented 2 years ago

Hi, this was due to the torch-optimizer update. Just fixed the issue by using torch-optmizer==0.1.0 in the setup. It should work now. Let me know if you still get the error.

abhijeetdesai14 commented 2 years ago

Hi, I am still facing the same issue. Can you please have a look. Thanks.