Track-Anything icon indicating copy to clipboard operation
Track-Anything copied to clipboard

Inpaint error - You are trying to inpaint without masks input

Open SQLCODE917 opened this issue 1 year ago • 15 comments

  • Running locally on Win11/4090 w/python 3.10.5 on pyenv Screenshot 2023-04-26 235638

  • Added video 10 second 720p video, selected 3 masks, clicked Tracking, success: Screenshot 2023-04-27 000128 Screenshot 2023-04-27 000158

  • Clicked inpaint, error like Error! You are trying to inpaint without masks input. Please track the selected mask first, and then press inpaint. If VRAM exceeded, please use the resize ratio to scaling down the image size.

    • Tried restarting from the beginning and setting the resizing ratio to .5, same error.

Screenshot 2023-04-27 000456

Screenshot 2023-04-27 000524

Is this the correct order of operations? Is there a step I'm missing to send the same masks that just worked for tracking to inpaint?

SQLCODE917 avatar Apr 27 '23 04:04 SQLCODE917

same error here. with no useful log to deal with

potatoker avatar Apr 27 '23 06:04 potatoker

Please try to set the resize ratio slider to 0.1. If it works, it means the GPU memory is exceeded in the previous operation.

memoryunreal avatar Apr 27 '23 06:04 memoryunreal

Finally get through this by doing the following:

  1. cut my whole uploaded video to shorter duration, resize ratio to smaller, click getInfo
  2. add the mask step by : click the object in the left "Image" box; click "Add mask" button above; click "Tracking"; click "inPainting".(I previously misunderstood the "add mask" button to click first before select object)

Not sure If it is the vram memory problem or the step problem

potatoker avatar Apr 27 '23 07:04 potatoker

Finally get through this by doing the following:

  1. cut my whole uploaded video to shorter duration, resize ratio to smaller, click getInfo
  2. add the mask step by : click the object in the left "Image" box; click "Add mask" button above; click "Tracking"; click "inPainting".(I previously misunderstood the "add mask" button to click first before select object)

Not sure If it is the vram memory problem or the step problem

It was vram problem in my test just now. When I set 0.1, I could run inpaint. It worked, but the effect was poor

zhanghongyong123456 avatar Apr 27 '23 07:04 zhanghongyong123456

We will add a VRAM monitor in the future, and sorry for the lack of an operation tutorial (incoming). For the VRAM problem, we are trying to optimize the RAM usage and VRAM usage.

memoryunreal avatar Apr 27 '23 07:04 memoryunreal

We will add a VRAM monitor in the future, and sorry for the lack of an operation tutorial (incoming). For the VRAM problem, we are trying to optimize the RAM usage and VRAM usage.

https://github.com/gaomingqi/Track-Anything/issues/21 My problem is still there

zhanghongyong123456 avatar Apr 27 '23 07:04 zhanghongyong123456

Please try to set the resize ratio slider to 0.1. If it works, it means the GPU memory is exceeded in the previous operation.

Unfortunately, the error persists, even at 0.1 ratio

Screenshot 2023-04-27 090647

Screenshot 2023-04-27 090601

I have also tried to cut the source video to 5 seconds, making it shorter than the 8 second parkour inpainting example video, set scale to 0.1, and it's still producing the same error

SQLCODE917 avatar Apr 27 '23 13:04 SQLCODE917

Please try to set the resize ratio slider to 0.1. If it works, it means the GPU memory is exceeded in the previous operation.

Unfortunately, the error persists, even at 0.1 ratio

Screenshot 2023-04-27 090647

Screenshot 2023-04-27 090601

I have also tried to cut the source video to 5 seconds, making it shorter than the 8 second parkour inpainting example video, set scale to 0.1, and it's still producing the same error

Maybe yours video's resolution two high, i test video 640X360,set Raise ratio=1, raise same error,Until the Raise ratio is set to 0.5,can run,you can set raise ratio 0.05 or lower

zhanghongyong123456 avatar Apr 28 '23 01:04 zhanghongyong123456

I tried it and works with ratio 0.5, but the masked objects are still in the output video. image

Beckjiang avatar Apr 28 '23 10:04 Beckjiang

Same issue RTX4090 (24Gb Vram) , tried to inpaint a 480x270p video thats only 25 f long and nothing, same error as everyone seems to be getting

I am on windows

finnschi avatar Apr 28 '23 12:04 finnschi

Screenshot 2023-04-28 214225

I pulled latest master today, scaled the video down to 360x180 and tried resize ratio all the way down to 1, 0.5 and even 0.02. I tried using only 1 mask - no luck, same error.

I also tried the lowest scale with the sample videos, just to be sure it's not just my own video - none of the sample videos I was able to inpaint.

SQLCODE917 avatar Apr 29 '23 01:04 SQLCODE917

@SQLCODE917 Hello. In the current version, inpainting cannot work without tracking results. So if you want to 'remove' an object in a video, first you should select and add the object mask, then click 'tracking' to locate the selected object throughout the video, and finally, click 'inpaint' for the inpainting results. Thanks.

gaomingqi avatar Apr 29 '23 02:04 gaomingqi

Thank you, yes - those are the steps that I have been using

SQLCODE917 avatar Apr 29 '23 02:04 SQLCODE917

It gives me an error if I try to mask then inpaint. It just says "Error" and I crashes.

WelschCode avatar Apr 29 '23 22:04 WelschCode

It gives me an error if I try to mask then inpaint. It just says "Error" and I crashes.

After you mask a target, you should track it first to get masks in the following frames and then inpaint it in the whole video

memoryunreal avatar May 08 '23 11:05 memoryunreal