[Bug] Outdated demos

#2914 · open · 2 comments

View on GitHub ↗

FeatureSpitter

### Branch main branch (1.x version, such as `v1.0.0`, or `dev-1.x` branch) ### Prerequisite - [x] I have searched [Issues](https://github.com/open-mmlab/mmaction2/issues) and [Discussions](https://github.com/open-mmlab/mmaction2/discussions) but cannot get the expected help. - [x] I have read the [documentation](https://mmaction2.readthedocs.io/en/latest/) but cannot get the expected help. - [x] The bug has not been fixed in the [latest version](https://github.com/open-mmlab/mmaction2). ### Environment mmaction2$ python utils/collect_env.py python: can't open file 'utils/collect_env.py': [Errno 2] No such file or directory ### Describe the bug If you install following these steps here: https://mmaction2.readthedocs.io/en/latest/get_started/installation.html You won't be able to run the demos, eg.: ``` (openmmlab) $ python demo/webcam_demo_spatiotemporal_det.py \ --input-video 0 \ --config configs/detection/slowonly/slowonly_kinetics400-pretrained-r101_8xb16-8x8x1-20e_ava21-rgb.py \ --checkpoint https://download.openmmlab.com/mmaction/detection/ava/slowonly_omnisource_pretrained_r101_8x8x1_20e_ava_rgb/slowonly_omnisource_pretrained_r101_8x8x1_20e_ava_rgb_20201217-16378594.pth \ --det-config demo/demo_configs/faster-rcnn_r50_fpn_2x_coco_infer.py \ --det-checkpoint http://download.openmmlab.com/mmdetection/v2.0/faster_rcnn/faster_rcnn_r50_fpn_2x_coco/faster_rcnn_r50_fpn_2x_coco_bbox_mAP-0.384_20200504_210434-a5d8aa15.pth \ --det-score-thr 0.9 \ --action-score-thr 0.5 \ --label-map tools/data/ava/label_map.txt \ --predict-stepsize 40 \ --output-fps 20 \ --show Traceback (most recent call last): File "demo/webcam_demo_spatiotemporal_det.py", line 23, in <module> from mmaction.structures import ActionDataSample File "/home/milhas/lixo/safecaring-demo/mmaction2/mmaction/__init__.py", line 16, in <module> assert (digit_version(mmcv_minimum_version) <= mmcv_version AssertionError: MMCV==2.2.0 is used but incompatible. Please install mmcv>=2.0.0rc4, <2.2.0. ``` ### Reproduces the problem - code sample _No response_ ### Reproduces the problem - command or script _No response_ ### Reproduces the problem - error message _No response_ ### Additional information _No response_

Comments

FeatureSpitter

Another instance of a broken demo here: https://github.com/open-mmlab/mmaction2/blob/main/demo/README.md#spatiotemporal-action-detection-webcam-demo By following the example command: ``` $ python demo/webcam_demo_spatiotemporal_det.py \ --input-video 0 \ --config configs/detection/slowonly/slowonly_kinetics400-pretrained-r101_8xb16-8x8x1-20e_ava21-rgb.py \ --checkpoint https://download.openmmlab.com/mmaction/detection/ava/slowonly_omnisource_pretrained_r101_8x8x1_20e_ava_rgb/slowonly_omnisource_pretrained_r101_8x8x1_20e_ava_rgb_20201217-16378594.pth \ --det-config demo/demo_configs/faster-rcnn_r50_fpn_2x_coco_infer.py \ --det-checkpoint http://download.openmmlab.com/mmdetection/v2.0/faster_rcnn/faster_rcnn_r50_fpn_2x_coco/faster_rcnn_r50_fpn_2x_coco_bbox_mAP-0.384_20200504_210434-a5d8aa15.pth \ --det-score-thr 0.9 \ --action-score-thr 0.5 \ --label-map tools/data/ava/label_map.txt \ --predict-stepsize 40 \ --output-fps 20 \ --show /home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmengine/optim/optimizer/zero_optimizer.py:11: DeprecationWarning: `TorchScript` support for functional optimizers is deprecated and will be removed in a future PyTorch release. Consider using the `torch.compile` optimizer instead. from torch.distributed.optim import \ Loads checkpoint by http backend from path: http://download.openmmlab.com/mmdetection/v2.0/faster_rcnn/faster_rcnn_r50_fpn_2x_coco/faster_rcnn_r50_fpn_2x_coco_bbox_mAP-0.384_20200504_210434-a5d8aa15.pth Loads checkpoint by http backend from path: https://download.openmmlab.com/mmaction/detection/ava/slowonly_omnisource_pretrained_r101_8x8x1_20e_ava_rgb/slowonly_omnisource_pretrained_r101_8x8x1_20e_ava_rgb_20201217-16378594.pth /home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmdet/apis/inference.py:90: UserWarning: dataset_meta or class names are not saved in the checkpoint's meta data, use COCO classes by default. warnings.warn( Traceback (most recent call last): File "demo/webcam_demo_spatiotemporal_det.py", line 864, in <module> main(parse_args()) File "demo/webcam_demo_spatiotemporal_det.py", line 793, in main stdet_predictor = StdetPredictor( File "demo/webcam_demo_spatiotemporal_det.py", line 298, in __init__ model = init_detector(config, checkpoint, device=device) File "/home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmdet/apis/inference.py", line 102, in init_detector metainfo = DATASETS.build(test_dataset_cfg).metainfo File "/home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmengine/registry/registry.py", line 570, in build return self.build_func(cfg, *args, **kwargs, registry=self) File "/home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmengine/registry/build_functions.py", line 121, in build_from_cfg obj = obj_cls(**args) # type: ignore File "/home/milhas/lixo/safecaring-demo/mmaction2/mmaction/datasets/ava_dataset.py", line 158, in __init__ self.proposals = load(self.proposal_file) File "/home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmengine/fileio/io.py", line 855, in load with BytesIO(file_backend.get(file)) as f: File "/home/milhas/anaconda3/envs/openmmlab/lib/python3.8/site-packages/mmengine/fileio/backends/local_backend.py", line 33, in get with open(filepath, 'rb') as f: FileNotFoundError: [Errno 2] No such file or directory: 'data/ava/annotations/ava_dense_proposals_val.FAIR.recall_93.9.pkl' /home/milhas/anaconda3/envs/openmmlab/lib/python3.8/tempfile.py:827: ResourceWarning: Implicitly cleaning up <TemporaryDirectory '/tmp/tmpw3v9ciw6'> _warnings.warn(warn_message, ResourceWarning) ```

nickmayn

is this repo still alive? It seems like the last time a commit was actually merged in was 2 years ago. Interested in building / collaborating on this, but not if its moved to a new home.