Skip to content

Always Problem Here: IndentationError in predictor.py when running on Colab #179

@cogniqube

Description

@cogniqube

I’m trying to run webui.py in the unmodified FasterLivePortrait-2.0 repo on Google Colab, but it always crashes with:
File URL: https://colab.research.google.com/drive/1jLe7FJLUQ2KyEkyuqLSD7fcekYwmD8uk?usp=sharing

IndentationError: expected an indented block after 'if' statement on line 48
  File "src/models/predictor.py", line 50
      else:
      ^

Steps to Reproduce

  1. Unzip and cd FasterLivePortrait-2.0/FasterLivePortrait-2.0
  2. Install requirements:
pip install -r requirements.txt
pip install onnxruntime-gpu

3.Run on Colab:

python webui.py \
  --mode cpu \
  --source_image "../face.jpg" \
  --driving_audio "../speech.wav" \
  --output_dir outputs

Expected Behavior
webui.py should start the pipeline and generate the talking-head video.

Actual Behavior
Crashes immediately with the IndentationError in src/models/predictor.py.

Environment

Google Colab

Python 3.11

onnxruntime-gpu installed

Any advice or quick patch would be greatly appreciated!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions