Skip to main content

MAGSAC and MAGSAC++

Project description

Important news

I am happy to announce that MAGSAC++ had been included in OpenCV. You can check the documentation at link. A comparison of OpenCV MAGSAC++ with the other robust estimators is at link thanks to Dmytro Mishkin.

OpenCV USAC Benchmark

The MAGSAC and MAGSAC++ algorithms for robust model fitting without using a single inlier-outlier threshold

The MAGSAC and MAGSAC++ algorithms proposed for robust model estimation without a single inlier-outlier threshold.

The MAGSAC paper is available at Link.

The MAGSAC++ available at Link.

Both methods are explained in the Latest developments in RANSAC presentation from CVPR tutorial RANSAC in 2020.

Experiments on homography, fundamental matrix, essential matrix, and 6D pose estimation are shown in the corresponding presentation from the tutorial RANSAC in 2020.

Tested on OpenCV 3.46 and 4.3. To run the executable with the examples, copy the "data" folder next to the executable or set the path in the main() function.

If you use the algorithm, please cite

@inproceedings{barath2019magsac,
	author = {Barath, Daniel and Matas, Jiri and Noskova, Jana},
	title = {{MAGSAC}: marginalizing sample consensus},
	booktitle = {Conference on Computer Vision and Pattern Recognition},
	year = {2019},
}

@inproceedings{barath2019magsacplusplus,
	author = {Barath, Daniel and Noskova, Jana and Ivashechkin, Maksym and Matas, Jiri},
	title = {{MAGSAC}++, a fast, reliable and accurate robust estimator},
	booktitle = {Conference on Computer Vision and Pattern Recognition},
	year = {2020},
}

Install from PyPI with pip

There are pre-compiled wheels for Windows and Linux for Python 3.8 - 3.11 that you can install with:

pip install pymagsac

Thanks to @akaszynski for his contributions.

Installation C++

To build and install C++-only MAGSAC/MAGSAC++, clone or download this repository and then build the project by CMAKE.

$ git clone https://github.com/danini/magsac --recursive
$ cd build
$ cmake ..
$ make

Install Python package and compile C++

python3 ./setup.py install

or

pip3 install -e .

Example project

To build the sample project showing examples of fundamental matrix, homography and essential matrix fitting, set variable CREATE_SAMPLE_PROJECT = ON when creating the project in CMAKE.

Next to the executable, copy the data folder and, also, create a results folder.

Jupyter Notebook example

The example for homography fitting is available at: notebook.

The example for fundamental matrix fitting is available at: notebook.

The example for essential matrix fitting is available at: notebook.

An example comparing different samplers on fundamental matrix estimation is available at: notebook.

Requirements

  • Eigen 3.0 or higher
  • CMake 2.8.12 or higher
  • OpenCV 3.0 or higher
  • A modern compiler with C++17 support
  • GFlags

Performance of MAGSAC++

MAGSAC++ is the state of the art according to "RANSAC in 2020" CVPR tutorial's experiments.

Performance of MAGSAC

MAGSAC is the state of the art according to the recent study Yin et.al."Image Matching across Wide Baselines: From Paper to Practice", 2020.

IMW-benchmark

IMW-Challenge

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pymagsac-0.2.3.tar.gz (3.4 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pymagsac-0.2.3-cp314-cp314-win_amd64.whl (3.8 MB view details)

Uploaded CPython 3.14Windows x86-64

pymagsac-0.2.3-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (5.5 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

pymagsac-0.2.3-cp313-cp313-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.13Windows x86-64

pymagsac-0.2.3-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (5.5 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

pymagsac-0.2.3-cp312-cp312-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.12Windows x86-64

pymagsac-0.2.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (5.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

pymagsac-0.2.3-cp311-cp311-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.11Windows x86-64

pymagsac-0.2.3-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (5.5 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

pymagsac-0.2.3-cp310-cp310-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.10Windows x86-64

pymagsac-0.2.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (5.5 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

File details

Details for the file pymagsac-0.2.3.tar.gz.

File metadata

  • Download URL: pymagsac-0.2.3.tar.gz
  • Upload date:
  • Size: 3.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pymagsac-0.2.3.tar.gz
Algorithm Hash digest
SHA256 e7e277f3a07b2d8e7eed689f5f3ef331ac15a92092e8b4d172b639ce28df7947
MD5 16dd835da0b9b04f2e1c76c3639185ec
BLAKE2b-256 f90aeb454aa8119c0d91433d23007fccd854947faee17a18939dd6bef1323e85

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3.tar.gz:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: pymagsac-0.2.3-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 3.8 MB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pymagsac-0.2.3-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 2a20f694bcea2d93fb9482964b233a14bb0916772adc9e624407b2be9c3ce8a9
MD5 e436b3d06fb921a51379ba8ad3a13922
BLAKE2b-256 2aecd942902056aa3aaaa8ff05fc6e9de04c2bc4fc881325f53b4bbf485afc4f

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp314-cp314-win_amd64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pymagsac-0.2.3-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 978dc81df6cee786bbcd4c225647e9535a1aaaf5e4a3957aaab335fd0fb3c86d
MD5 02b20477fd6e27c618a1db17d2542888
BLAKE2b-256 1502bee063bdd88be5b84e35fc255b71a51c45f18cd66a2e69c2d99c040abad4

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: pymagsac-0.2.3-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pymagsac-0.2.3-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 50611631dc9283f4ce0d8257a39fa69afab70984f78b185248846d4959db7537
MD5 2f95db9ce3457b936230e78390b0645b
BLAKE2b-256 4efb4e4b4e742235f79fe23c1dc7e4c068693ef3daf9f9940bde465f4c110af2

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp313-cp313-win_amd64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pymagsac-0.2.3-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 97450545421efdf7bcc852620a0f2917991805a21d221be7858e213fbbdd4017
MD5 55bc5f23b5e0bc3b24f0efdd1e041304
BLAKE2b-256 b3a7e1d71df8af2c050a3c1c3fac5a3eee9b631df65f884b38ebcb7c9ecc2cfe

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: pymagsac-0.2.3-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pymagsac-0.2.3-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 c0786a622fe80628e474f1a7ad5f1d9f39b7045a9546fb3944aa27f39e819b43
MD5 56aa4f13d97597c05540c24b6b20cfbf
BLAKE2b-256 888f0d6762ed62695da8de9c1ee31fbed2982e2721681dc837b43a575cc0daa5

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp312-cp312-win_amd64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pymagsac-0.2.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 bea97a54559b12c0180a7c57e950876ab61eaccf72a5efd731db22581fe6110e
MD5 bfb4a1f87a16583642c921f317ff9f8c
BLAKE2b-256 4673ab6c31d854e90cdfe2333646061b3f03bf5cfae3eeb1cc2fda5aaac6a3ef

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: pymagsac-0.2.3-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pymagsac-0.2.3-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 5593676d1c1dcc75bbbbd26ab7c7f04277e925a6fd8bc3f16970e9472373bfdd
MD5 ae58256d4f36a9b589af6ee9def7879c
BLAKE2b-256 3f96a034b1b3bf9f52430c0704e57a3f1a7344305cf5547fe22786eceecd3226

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp311-cp311-win_amd64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pymagsac-0.2.3-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 68ddfbfabf0f5b20be1e295a83641cace13d764dc644a11b2114ade57f475da7
MD5 a5f4c7e4d5d033e9d05d755465be2edb
BLAKE2b-256 c6ba52fa862eaee6ec0d45e056db4881adbf43983e64949acb9e029f23ec5c42

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: pymagsac-0.2.3-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pymagsac-0.2.3-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 bf87fd03c3ca0667af5a5f3c9779756982593bfb07ad726eaf6f3fa25208fac0
MD5 80e5e2d48b9f611a801af33695aa4e9d
BLAKE2b-256 cfb16a2b3d1003850124a8cb994e6ba77958778fb39f8c2e94c1880ad6d3c3ed

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp310-cp310-win_amd64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymagsac-0.2.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pymagsac-0.2.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 82b864c90d8bfd8be397516ba7e70d795a72d414e31b80aa82d93b1fef2f128e
MD5 4afe872987358415d191685b86f8b659
BLAKE2b-256 a14af46284915285dd604bd3725c11a3037dfb5414a3e19580fe546df199c166

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymagsac-0.2.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: build-and-deploy.yml on danini/magsac

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page