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

AttributeError: 'ImageBoxState' object has no attribute 'raw_image' #13

Open
MuHeDing opened this issue Aug 16, 2024 · 3 comments
Open

Comments

@MuHeDing
Copy link

Traceback (most recent call last):
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/gradio/queueing.py", line 388, in call_prediction
output = await route_utils.call_process_api(
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/gradio/route_utils.py", line 219, in call_process_api
output = await app.get_blocks().process_api(
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/gradio/blocks.py", line 1437, in process_api
result = await self.call_function(
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/gradio/blocks.py", line 1109, in call_function
prediction = await anyio.to_thread.run_sync(
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/anyio/to_thread.py", line 56, in run_sync
return await get_async_backend().run_sync_in_worker_thread(
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 2144, in run_sync_in_worker_thread
return await future
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 851, in run
result = context.run(func, *args)
File "/ssd/des/anaconda3/envs/vitron/lib/python3.10/site-packages/gradio/utils.py", line 641, in wrapper
response = f(*args, **kwargs)
File "/ssd/des/Vitron/app.py", line 596, in predict
AttributeError: 'ImageBoxState' object has no attribute 'raw_image'

How to fix this debug?

@HaoyuanShi
Copy link

Same problem. Have you solved this?

@CiChina
Copy link

CiChina commented Dec 16, 2024

I reviewed the code in app.py and util. You can try changing the .raw_image attribute of the object to the .image attribute.
Uploading image.png…

@CiChina
Copy link

CiChina commented Dec 16, 2024

Uploading 1eb078b3-2ecf-469a-8ffd-365ed4e1d2ad.png…

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