facebookresearch / facebookresearch/meshflow

KeyError: 0 in Gradio 6.6.0 when running gradio_app.py on Windows 11

Open
#11 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
512
Forks
27
PR merge metrics
No merged PRs in 30d

Description

I have successfully installed MeshFlow on Windows 11 with Python 3.10 and RTX 5090. The command-line inference via inference_dit.py works perfectly.

However, when I try to launch the Gradio web interface with:

python gradio_app.py --gpu 0 --dtype fp16 --model_path ckpt/meshflow
The server starts and shows:

* Running on local URL: http://0.0.0.0:7860
But when I upload a .ply mesh file and click the "Generate" button, the following error appears in the console:

Traceback (most recent call last):
File "C:\Users\Admin\meshflow_workspace\meshflow\venv\lib\site-packages\gradio\queueing.py", line 766, in process_events
response = await route_utils.call_process_api(
File "C:\Users\Admin\meshflow_workspace\meshflow\venv\lib\site-packages\gradio\route_utils.py", line 355, in call_process_api
output = await app.get_blocks().process_api(
File "C:\Users\Admin\meshflow_workspace\meshflow\venv\lib\site-packages\gradio\blocks.py", line 2153, in process_api
inputs = await self.preprocess_data(
File "C:\Users\Admin\meshflow_workspace\meshflow\venv\lib\site-packages\gradio\blocks.py", line 1761, in preprocess_data
processed_input.append(state[block._id])
File "C:\Users\Admin\meshflow_workspace\meshflow\venv\lib\site-packages\gradio\state_holder.py", line 84, in __getitem__
block = self.blocks_config.blocks[key]
KeyError: 0
Steps to reproduce:

Fresh clone of MeshFlow on Windows 11.

Created virtual environment with Python 3.10.

Installed dependencies using pip install -r requirements.txt (after fixing the torch/torchvision conflict to torch==2.8.0 + torchvision==0.23.0 as you confirmed).

Placed the downloaded config.yaml and model.pth in ckpt/meshflow/.

Launched the demo with python gradio_app.py --gpu 0 --dtype fp16 --model_path ckpt/meshflow.

Uploaded a .ply file and clicked "Generate".

Received the KeyError: 0 as shown above.

Additional details:

OS: Windows 11 (Version 10.0.26200.8655)

Python: 3.10

Gradio version: 6.6.0 (installed from requirements.txt)

PyTorch: 2.8.0+cu128

torchvision: 0.23.0+cu128

Note: The command-line inference works correctly, so this issue is specific to the Gradio interface.

Questions:

Is this a known issue with Gradio 6.6.0?

Do you recommend using a different version of Gradio (e.g., 5.9.0 or 6.7.0+) that is known to work?

Could you please update requirements.txt to specify a working Gradio version for Windows?

Thank you for your assistance.

Contributor guide

Open the contributing guide

Research direction

Start with gradio_app.py and requirements.txt, then reproduce the Windows 11 failure by uploading a .ply file and clicking Generate. Compare the declared Gradio dependency with the reported 6.6.0 environment and verify the interface completes inference without KeyError: 0. Done means the supported dependency is recorded and the Gradio workflow works while command-line inference remains unaffected.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.