Skip to content

ayushkumar8340/xfeat_cpp_with_CV

 
 

Repository files navigation

C++ Implementation of XFeat

This repo contains the C++ implementation of the CVPR 2024 paper XFeat: Accelerated Features for Lightweight Image Matching.

Original Repo: https://github.com/verlab/accelerated_features

Paper: https://arxiv.org/abs/2404.19174

Image Matches

Prerequisite

In this project, the following packages are used. Make sure the right versions of libraries are installed and linked.

  1. Tested in Ubuntu 22.04 / 20.04
  2. Nvidia-driver-535 and CUDA Toolkit 12.2
  3. gcc and g++ compilers 11.4.0
  4. CMake 3.22.1 / 3.5
  5. OpenCV 4.5.4 / 4.1.1
  6. libtorch: Please avoid using the pre-built version of libtorch since it will cause linking issues (CXX11 ABI issue)

Setup

To download the project:

git clone https://github.com/udaysankar01/xfeat_cpp
cd xfeat_cpp

To install the necessary packages (OpenCV and libtorch):

chmod +x project_setup.sh
./project_setup.sh

To build the project:

mkdir -p build
cd build
cmake ..
make -j4

To build the project using Docker

sudo docker build -t xfeat . 
            or
./build_docker.sh
xhost + (in different terminal)
./run_docker.sh xfeat
mkdir build 
cd build
cmake ..
make -j4

Running

To perform matching between two images, use this command:

./build/examples/example /absolute/path/to/image1 /absolute/path/to/image2

Matching Example:

./build/examples/match $(pwd)/ref.png $(pwd)/tgt.png

Realtime Matching Example:

./build/examples/realtime_demo

Realsense Matching Example:

./build/realsense_demo

Bibtex Citation

@misc{potje2024xfeatacceleratedfeatureslightweight,
      title={XFeat: Accelerated Features for Lightweight Image Matching},
      author={Guilherme Potje and Felipe Cadar and Andre Araujo and Renato Martins and Erickson R. Nascimento},
      year={2024},
      eprint={2404.19174},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/2404.19174},
}

About

The C++ Implementation of XFeat (Accelerated Features).

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 89.3%
  • Dockerfile 5.8%
  • CMake 3.2%
  • Shell 1.7%