z-x-yang / Segment-and-Track-Anything

An open-source project dedicated to tracking and segmenting any objects in videos, either automatically or interactively. The primary algorithms utilized include the Segment Anything Model (SAM) for key-frame segmentation and Associating Objects with Transformers (AOT) for efficient tracking and propagation purposes.
GNU Affero General Public License v3.0
2.77k stars 334 forks source link

error while running python ./app.py #113

Open andysingal opened 10 months ago

andysingal commented 10 months ago

Hi, Thanks for the amazing repo, while running the code:

$ git clone https://github.com/z-x-yang/Segment-and-Track-Anything.git
$ cd Segment-and-Track-Anything

$ chmod a+x script/install.sh 
$ ./script/install.sh

#download models
$ chmod a+x script/download_ckpt
$./script/download_ckpt.sh

i had no issues when i run:

python ./app.py

i got error

/usr/local/lib/python3.10/dist-packages/gradio/layouts/column.py:55: UserWarning: 'scale' value should be an integer. Using 0.5 will cause issues.
  warnings.warn(
Traceback (most recent call last):
  File "/workspace/Segment-and-Track-Anything/./app.py", line 1106, in <module>
    seg_track_app()
  File "/workspace/Segment-and-Track-Anything/./app.py", line 485, in seg_track_app
    input_video = gr.Video(label='Input video').style(height=550)
AttributeError: 'Video' object has no attribute 'style'. Did you mean: 'scale'?

tried to upgrade gadio it did not solve the issue(Note: also checked Gradio documentation : https://www.gradio.app/docs/video). Any assistance to resolve this issue is appreciated Thanks, Andy

yamy-cheng commented 10 months ago

Hi,use pip install gradio==3.38.0 to install gradio which support the code.