You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Context:
I noticed this issue when I was working on submitting my own metric to the hub. At the top of the page, it keeps on asking me to update the Gradio version.
Error:
Upon updating it, I got the following error - AttributeError: module 'gradio' has no attribute 'inputs'.
Reason:
Upon further digging, I think the issue is occurs whenever you upgrade Gradio to version >=4.0. Turns out from version 4 onwards, gradio.inputs has been removed as you can see in the __init__file. However, evaluate library calls it in launch_gradio_widget function in utilsdir.
Solution:
A simple solution would be to limit the dependency below Gradio version 4.0.0. This can be done by simply updating the line 63 in setup.py file. More specifically, instead of - "gradio>=3.0.0", it can be chnaged to "gradio>=3.0.0, <4.0.0" to fix the issue.
P.S. - I am still working on the metric so the page might go down until I fully complete it.
The text was updated successfully, but these errors were encountered:
I think that another solution would be to modify the code in src/evaluate/utils/gradio.py to change the syntax of the depreciated gr.inputs and gr.outputs to use the interface components directly.
For maintaining current available evaluate metrics, the implementation can differ based on the version (an if statement would do).
Yes, I'm seeing this as well with my own metrics on the Hugging Face Hub. The Hugging Face Hub is currently prompting everyone to upgrade to the latest gradio 4.xx.xx version (see screenshot), so this issue will break many metrics spaces.
Context:
I noticed this issue when I was working on submitting my own metric to the hub. At the top of the page, it keeps on asking me to update the Gradio version.
Error:
Upon updating it, I got the following error -
AttributeError: module 'gradio' has no attribute 'inputs'
.Reason:
Upon further digging, I think the issue is occurs whenever you upgrade Gradio to version
>=4.0
. Turns out from version 4 onwards,gradio.inputs
has been removed as you can see in the__init__
file. However,evaluate
library calls it inlaunch_gradio_widget
function inutils
dir.Solution:
A simple solution would be to limit the dependency below Gradio version 4.0.0. This can be done by simply updating the line 63 in
setup.py
file. More specifically, instead of -"gradio>=3.0.0"
, it can be chnaged to"gradio>=3.0.0, <4.0.0"
to fix the issue.P.S. - I am still working on the metric so the page might go down until I fully complete it.
The text was updated successfully, but these errors were encountered: