代码idx存在问题
haoyuying opened this issue · comments
https://github.com/hkchengrex/MiVOS/blob/main/davis_processor.py#L63
这一行代码中的idx没有定义,如果是上面for的定义,已经被释放,且return idx用for的定义也说不通,请问这个idx的定义在哪里呢,期待您的回复。
Huh, that's interesting. It shouldn't work at all if this is bugged! I will look into it. Thanks for reporting.
Ah, I remembered. It's not a bug.
If you print all_scr
, you can see that it is a list containing all the frames (I don't know why they designed it this way, but I am just using their API) with only the frame being interacted populated with the scribble information. We detect the interacted frame with if len(s) != 0
and break
after that. So idx
will correctly stay at the interacted frame after the loop.
I will add some comments there.