vye16 / shape-of-motion

MIT License
741 stars 47 forks source link

Issues with save masks #42

Open DWJ111 opened 4 weeks ago

DWJ111 commented 4 weeks ago

Hi, when I tried preprocessing, I encountered this error: "Current selection" and "Masked video" don't have pictures. QQ图片20240818194033

qianqianwang68 commented 2 weeks ago

Do you see any errors in the terminal?

liyaowei-stu commented 2 weeks ago

same problem.

xizaoqu commented 2 weeks ago

Hi, it is the gradio problem. The newest version has bugs in Image.select(). Try to downgrade it into like 4.13.0.

ricshaw commented 2 weeks ago

I downgraded Gradio and now I can see the selection, but the tracking doesn't work. I just get an error.

image

Traceback (most recent call last): File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/gradio/queueing.py", line 489, in call_prediction output = await route_utils.call_process_api( File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/gradio/route_utils.py", line 232, in call_process_api output = await app.get_blocks().process_api( File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/gradio/blocks.py", line 1561, in process_api result = await self.call_function( File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/gradio/blocks.py", line 1179, in call_function prediction = await anyio.to_thread.run_sync( File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/anyio/to_thread.py", line 56, in run_sync return await get_async_backend().run_sync_in_worker_thread( File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 2177, in run_sync_in_worker_thread return await future File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 859, in run result = context.run(func, args) File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/gradio/utils.py", line 678, in wrapper response = f(args, **kwargs) File "/home/ma-user/work/richards/shape-of-motion/preproc/mask_app.py", line 162, in run_tracker self.lazy_init_tracker() File "/home/ma-user/work/richards/shape-of-motion/preproc/mask_app.py", line 48, in lazy_init_tracker self.tracker = init_tracker(self.checkpoint_dir, self.device) File "/home/ma-user/work/richards/shape-of-motion/preproc/mask_utils.py", line 27, in init_tracker return BaseTracker(checkpoints[-1], device) File "/home/ma-user/work/richards/shape-of-motion/preproc/tracker/base_tracker.py", line 33, in init network = XMem(config, xmem_checkpoint).to(device).eval() File "/home/ma-user/work/richards/shape-of-motion/preproc/tracker/model/network.py", line 23, in init model_weights = self.init_hyperparameters(config, model_path, map_location) File "/home/ma-user/work/richards/shape-of-motion/preproc/tracker/model/network.py", line 176, in init_hyperparameters model_weights = torch.load(model_path, map_location="cpu") File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/torch/serialization.py", line 1005, in load with _open_zipfile_reader(opened_file) as opened_zipfile: File "/home/ma-user/miniconda3/envs/gaussian_splatting/lib/python3.10/site-packages/torch/serialization.py", line 457, in init super().init(torch._C.PyTorchFileReader(name_or_buffer)) RuntimeError: PytorchStreamReader failed reading zip archive: failed finding central director

ricshaw commented 2 weeks ago

Nevermind, it seems the XMem checkpoint didn't download correctly or was corrupted