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

Utils issue on Comic_Generation.ipynb notebook #145

Open
Barth44 opened this issue Jul 14, 2024 · 2 comments
Open

Utils issue on Comic_Generation.ipynb notebook #145

Barth44 opened this issue Jul 14, 2024 · 2 comments

Comments

@Barth44
Copy link

Barth44 commented Jul 14, 2024

This code from the notebook gives errors.

%load_ext autoreload

%autoreload 2

import gradio as gr
import numpy as np
import torch
import requests
import random
import os
import sys
import pickle
from PIL import Image
from tqdm.auto import tqdm
from datetime import datetime
from utils.gradio_utils import is_torch2_available
if is_torch2_available():
from utils.gradio_utils import
AttnProcessor2_0 as AttnProcessor
else:
from utils.gradio_utils import AttnProcessor

import diffusers
from diffusers import StableDiffusionXLPipeline
from diffusers import DDIMScheduler
import torch.nn.functional as F
from utils.gradio_utils import cal_attn_mask_xl
import copy
import os
from diffusers.utils import load_image
from utils.utils import get_comic
from utils.style_template import styles

ModuleNotFoundError Traceback (most recent call last)
in <cell line: 14>()
12 from tqdm.auto import tqdm
13 from datetime import datetime
---> 14 from utils.gradio_utils import is_torch2_available
15 if is_torch2_available():
16 from utils.gradio_utils import \

ModuleNotFoundError: No module named 'utils.gradio_utils'

@MalikMouazer
Copy link

The "gradio_utils.py" file is in the utils folder of StoryDiffusion

@hrushik98
Copy link

hey, you probably did not clone the repo. As Malik as mentioned, you need to clone the repo first and then run the colab file. The gradio_utils.py is a part of the utils folder that you will have only if you clone the repo.
Hopefully this helps!

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

3 participants