• Stars
    star
    5,626
  • Rank 6,930 (Top 0.2 %)
  • Language
    Python
  • License
    Apache License 2.0
  • Created over 5 years ago
  • Updated 8 days ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

OpenMMLab Computer Vision Foundation
 
OpenMMLab website HOT      OpenMMLab platform TRY IT OUT
 

platform PyPI - Python Version pytorch cuda PyPI badge codecov license

📘Documentation | 🛠️Installation | 🤔Reporting Issues

English | 简体中文

Highlights

The OpenMMLab team released a new generation of training engine MMEngine at the World Artificial Intelligence Conference on September 1, 2022. It is a foundational library for training deep learning models. Compared with MMCV, it provides a universal and powerful runner, an open architecture with a more unified interface, and a more customizable training process.

MMCV v2.0.0 official version was released on April 6, 2023. In version 2.x, it removed components related to the training process and added a data transformation module. Also, starting from 2.x, it renamed the package names mmcv to mmcv-lite and mmcv-full to mmcv. For details, see Compatibility Documentation.

MMCV will maintain both 1.x (corresponding to the original master branch) and 2.x (corresponding to the main branch, now the default branch) versions simultaneously. For details, see Branch Maintenance Plan.

Introduction

MMCV is a foundational library for computer vision research and it provides the following functionalities:

It supports the following systems:

  • Linux
  • Windows
  • macOS

See the documentation for more features and usage.

Note: MMCV requires Python 3.7+.

Installation

There are two versions of MMCV:

  • mmcv: comprehensive, with full features and various CUDA ops out of the box. It takes longer time to build.
  • mmcv-lite: lite, without CUDA ops but all other features, similar to mmcv<1.0.0. It is useful when you do not need those CUDA ops.

Note: Do not install both versions in the same environment, otherwise you may encounter errors like ModuleNotFound. You need to uninstall one before installing the other. Installing the full version is highly recommended if CUDA is available.

Install mmcv

Before installing mmcv, make sure that PyTorch has been successfully installed following the PyTorch official installation guide. For apple silicon users, please use PyTorch 1.13+.

The command to install mmcv:

pip install -U openmim
mim install mmcv

If you need to specify the version of mmcv, you can use the following command:

mim install mmcv==2.0.0

If you find that the above installation command does not use a pre-built package ending with .whl but a source package ending with .tar.gz, you may not have a pre-build package corresponding to the PyTorch or CUDA or mmcv version, in which case you can build mmcv from source.

Installation log using pre-built packages

Looking in links: https://download.openmmlab.com/mmcv/dist/cu102/torch1.8.0/index.html
Collecting mmcv
Downloading https://download.openmmlab.com/mmcv/dist/cu102/torch1.8.0/mmcv-2.0.0-cp38-cp38-manylinux1_x86_64.whl

Installation log using source packages

Looking in links: https://download.openmmlab.com/mmcv/dist/cu102/torch1.8.0/index.html
Collecting mmcv==2.0.0
Downloading mmcv-2.0.0.tar.gz

For more installation methods, please refer to the Installation documentation.

Install mmcv-lite

If you need to use PyTorch-related modules, make sure PyTorch has been successfully installed in your environment by referring to the PyTorch official installation guide.

pip install -U openmim
mim install mmcv-lite

FAQ

If you face some installation issues, CUDA related issues or RuntimeErrors, you may first refer to this Frequently Asked Questions.

If you face installation problems or runtime issues, you may first refer to this Frequently Asked Questions to see if there is a solution. If the problem is still not solved, feel free to open an issue.

Citation

If you find this project useful in your research, please consider cite:

@misc{mmcv,
    title={{MMCV: OpenMMLab} Computer Vision Foundation},
    author={MMCV Contributors},
    howpublished = {\url{https://github.com/open-mmlab/mmcv}},
    year={2018}
}

Contributing

We appreciate all contributions to improve MMCV. Please refer to CONTRIBUTING.md for the contributing guideline.

License

MMCV is released under the Apache 2.0 license, while some specific operations in this library are with other licenses. Please refer to LICENSES.md for the careful check, if you are using our code for commercial matters.

Branch Maintenance Plan

MMCV currently has four branches, namely main, 1.x, master, and 2.x, where 2.x is an alias for the main branch, and master is an alias for the 1.x branch. The 2.x and master branches will be deleted in the future. MMCV's branches go through the following three stages:

Phase Time Branch description
RC Period 2022.9.1 - 2023.4.5 Release candidate code (2.x version) will be released on 2.x branch. Default master branch is still 1.x version Master and 2.x branches iterate normally
Compatibility Period 2023.4.6 - 2023.12.31 The 2.x branch has been renamed to the main branch and set as the default branch, and 1.x branch will correspond to 1.x version We still maintain the old version 1.x, respond to user needs, but try not to introduce changes that break compatibility; main branch iterates normally
Maintenance Period From 2024/1/1 Default main branch corresponds to 2.x version and 1.x branch is 1.x version 1.x branch is in maintenance phase, no more new feature support; main branch is iterating normally

Projects in OpenMMLab

  • MMEngine: OpenMMLab foundational library for training deep learning models.
  • MMCV: OpenMMLab foundational library for computer vision.
  • MIM: MIM installs OpenMMLab packages.
  • MMClassification: OpenMMLab image classification toolbox and benchmark.
  • MMDetection: OpenMMLab detection toolbox and benchmark.
  • MMDetection3D: OpenMMLab's next-generation platform for general 3D object detection.
  • MMRotate: OpenMMLab rotated object detection toolbox and benchmark.
  • MMYOLO: OpenMMLab YOLO series toolbox and benchmark.
  • MMSegmentation: OpenMMLab semantic segmentation toolbox and benchmark.
  • MMOCR: OpenMMLab text detection, recognition, and understanding toolbox.
  • MMPose: OpenMMLab pose estimation toolbox and benchmark.
  • MMHuman3D: OpenMMLab 3D human parametric model toolbox and benchmark.
  • MMSelfSup: OpenMMLab self-supervised learning toolbox and benchmark.
  • MMRazor: OpenMMLab model compression toolbox and benchmark.
  • MMFewShot: OpenMMLab fewshot learning toolbox and benchmark.
  • MMAction2: OpenMMLab's next-generation action understanding toolbox and benchmark.
  • MMTracking: OpenMMLab video perception toolbox and benchmark.
  • MMFlow: OpenMMLab optical flow toolbox and benchmark.
  • MMEditing: OpenMMLab image and video editing toolbox.
  • MMGeneration: OpenMMLab image and video generative models toolbox.
  • MMDeploy: OpenMMLab model deployment framework.

More Repositories

1

mmdetection

OpenMMLab Detection Toolbox and Benchmark
Python
27,899
star
2

mmsegmentation

OpenMMLab Semantic Segmentation Toolbox and Benchmark.
Python
7,372
star
3

mmagic

OpenMMLab Multimodal Advanced, Generative, and Intelligent Creation Toolbox. Unlock the magic 🪄: Generative-AI (AIGC), easy-to-use APIs, awsome model zoo, diffusion models, for text-to-image generation, image/video restoration/enhancement, etc.
Jupyter Notebook
6,575
star
4

mmpose

OpenMMLab Pose Estimation Toolbox and Benchmark.
Python
4,969
star
5

mmdetection3d

OpenMMLab's next-generation platform for general 3D object detection.
Python
4,781
star
6

OpenPCDet

OpenPCDet Toolbox for LiDAR-based 3D Object Detection.
Python
4,342
star
7

mmocr

OpenMMLab Text Detection, Recognition and Understanding Toolbox
Python
4,099
star
8

Amphion

Amphion (/æmˈfaɪən/) is a toolkit for Audio, Music, and Speech Generation. Its purpose is to support reproducible research and help junior researchers and engineers get started in the field of audio, music, and speech generation research and development.
Python
3,947
star
9

mmaction2

OpenMMLab's Next Generation Video Understanding Toolbox and Benchmark
Python
3,903
star
10

mmtracking

OpenMMLab Video Perception Toolbox. It supports Video Object Detection (VID), Multiple Object Tracking (MOT), Single Object Tracking (SOT), Video Instance Segmentation (VIS) with a unified framework.
Python
3,384
star
11

mmpretrain

OpenMMLab Pre-training Toolbox and Benchmark
Python
3,138
star
12

mmselfsup

OpenMMLab Self-Supervised Learning Toolbox and Benchmark
Python
3,084
star
13

mmskeleton

A OpenMMLAB toolbox for human pose estimation, skeleton-based action recognition, and action synthesis.
Python
2,855
star
14

mmyolo

OpenMMLab YOLO series toolbox and benchmark. Implemented RTMDet, RTMDet-Rotated,YOLOv5, YOLOv6, YOLOv7, YOLOv8,YOLOX, PPYOLOE, etc.
Python
2,719
star
15

mmdeploy

OpenMMLab Model Deployment Framework
Python
2,520
star
16

mmaction

An open-source toolbox for action understanding based on PyTorch
Python
1,847
star
17

mmgeneration

MMGeneration is a powerful toolkit for generative models, based on PyTorch and MMCV.
Python
1,796
star
18

mmrotate

OpenMMLab Rotated Object Detection Toolbox and Benchmark
Python
1,724
star
19

Multimodal-GPT

Multimodal-GPT
Python
1,397
star
20

mmrazor

OpenMMLab Model Compression Toolbox and Benchmark.
Python
1,366
star
21

mmfashion

Open-source toolbox for visual fashion analysis based on PyTorch
Python
1,204
star
22

mmhuman3d

OpenMMLab 3D Human Parametric Model Toolbox and Benchmark
Python
1,129
star
23

mmengine

OpenMMLab Foundational Library for Training Deep Learning Models
Python
1,029
star
24

playground

A central hub for gathering and showcasing amazing projects that extend OpenMMLab with SAM and other exciting features.
Python
1,017
star
25

OpenMMLabCourse

OpenMMLab course index and stuff
Jupyter Notebook
919
star
26

mmflow

OpenMMLab optical flow toolbox and benchmark
Python
889
star
27

PIA

[CVPR 2024] PIA, your Personalized Image Animator. Animate your images by text prompt, combing with Dreambooth, achieving stunning videos. PIA,你的个性化图像动画生成器,利用文本提示将图像变为奇妙的动画
Python
716
star
28

mmfewshot

OpenMMLab FewShot Learning Toolbox and Benchmark
Python
662
star
29

awesome-vit

396
star
30

OpenUnReID

PyTorch open-source toolbox for unsupervised or domain adaptive object re-ID.
Python
389
star
31

labelbee-client

Out-of-the-box Annotation Toolbox
JavaScript
374
star
32

mim

MIM Installs OpenMMLab Packages
Python
329
star
33

denseflow

Extracting optical flow and frames
C++
286
star
34

MMGEN-FaceStylor

Python
245
star
35

mmeval

A unified evaluation library for multiple machine learning libraries
Python
243
star
36

labelbee

LabelBee is an annotation Library
TypeScript
223
star
37

OpenMMLabCamp

Jupyter Notebook
92
star
38

polynet

The Github Repo for PolyNet
77
star
39

CLUE

C++ Lightweight Utility Extensions
C++
70
star
40

mim-example

Python
57
star
41

mmengine-template

Python
47
star
42

ecosystem

36
star
43

mmstyles

Latex style file to facilitate writing of technical papers
TeX
36
star
44

mmpose-webcam-demo

Python
23
star
45

pre-commit-hooks

Python
17
star
46

mdformat-openmmlab

Python
8
star
47

.github

3
star