-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
AttributeError: module 'gradio' has no attribute 'inputs' #605
Comments
Facing the same problem. |
I had the same issue as well, if you just want to generate outputs for some input prompts and you don't need to gradio interface then you can prompt the model like this: https://github.com/Nimisha-Pabbichetty/alpaca-lora/blob/main/generate.py |
I also faced the same problem. The solution that worked for me is to install an older version of Gradio. |
pip install gradio==3.50 was ok tks |
Actionable suggestions, thanks for sharing |
I fixed the issues by using Components from |
I am facing the same issue and gradio==3.50 does not seem to fix it |
Hi! I'm very new in all of this so I'd appreciate your help. |
This does work thanks and good luck !pip install gradio==3.43.1 |
gradio deprecated
|
#@title Demo UI def generate_image(seed, c0, c1, c2, c3, c4, c5, c6):
Create a number input for seedseed = gr.inputs.Number(default=0, label="Seed 1") slider_max_val = 20 Create the sliders inputc0 = gr.inputs.Slider(label="Sleeve & Size", minimum=slider_min_val, maximum=slider_max_val, default=0) inputs = [seed, c0, c1, c2, c3, c4, c5, c6] Launch demogr.Interface(generate_image, inputs, ["image"], live=True, title="ClothingGAN").launch(debug=True) AttributeError Traceback (most recent call last) AttributeError: module 'gradio' has no attribute 'inputs' |
This is so helpful. I was able to make it work when I realized gradio deprecated input/output into simply components. Thank you again @alexandrabindas |
thank you for sharing |
Thank you very much. |
Hey, |
The error you people are encountering is due to using deprecated attribute names in Gradio. As of Gradio v3.0 and later, the module attributes inputs and outputs have been replaced with components. You could use like gr.Textbox for both input and output |
For those who want to run the Docker Setup & Inference in the main branch, and get a similar error.
|
Hi,
I am running
python generate.py
and found that in the most recent version ofgradio
, they have changed theirgradio.inputs.Textbox
togradio.Textbox
, so I encountered the following errors.Although most users should be able to fix it, I think maybe you can either update this script or specify a fixed version of
gradio
inrequirements.txt
?The text was updated successfully, but these errors were encountered: