Home

Awesome

RISG: A rotation invariant SuperGlue algorithm.

Overview

A rotation invariant SuperGlue matching algorithm for cross modality image also see here, https://gitee.com/ssacn/RISG-image-matching

Some results:

Getting start:

Python 3.7+ is recommended for running our code. Conda can be used to install the required packages:

Dependencies

Dataset

We collected a set of test data, including images from space-borne SAR and visible light sensors, drone thermal infrared sensors, and Google Earth images. You may find them in the directory "test" in this repository.

Usage

just for test

risgmatching.py contains the majority of the code. Run test_risg.py for testing:

python3 test_risg.py

Using RISG in your code

    with open('./config.yaml', 'r') as f:
        config = yaml.safe_load(f)
        risg = RISGMatcher(config)

        img_filename0 = 'test/01/pair1.jpg'
        img_filename1 = 'test/01/pair2.jpg'

        img0 = cv2.imread(img_filename0)
        img1 = cv2.imread(img_filename1)
        # rotate is number of directions
        mkpts0, mkpts1, conf, main_dir = risg.match(img0,img1,nrotate = 5)