An Improved ORB Feature Extraction Algorithm Based
An Improved ORB Feature Extraction Algorithm Based
This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
ABSTRACT The ORB (Oriented fast and rotated brief, ORB) algorithm is limited by its inability to
extract feature points or extract only a small number of feature points when a fixed threshold is used in
complex lighting conditions. To address this issue, this study proposes a method that combines image
enhancement with truncated adaptive threshold to improve the ORB feature extraction algorithm. Firstly, the
original image is converted to grayscale. Secondly, the image is enhanced by applying Gaussian filtering for
noise reduction, truncated adaptive gamma brightness adjustment, and unsharp masking operation. Then,
the enhanced image is segmented into subregions of a specified size, and an improved truncated OTUS
method is employed to calculate the adaptive threshold for each subregion. Finally, ORB feature points
are extracted using the adaptive threshold. Experimental results show that the improved ORB algorithm
can significantly increase the number of feature points in complex lighting conditions, with good accuracy,
real-time performance, and robustness.
INDEX TERMS Feature extraction; ORB; image enhancement; adaptive threshold; OTUS
VOLUME 4, 2022 1
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
Therefore, addressing the problem of lighting variations is demonstrate the effectiveness and practicality of the proposed
one of the key challenges in improving the performance of algorithm in various scenarios, indicating promising applica-
the ORB feature extraction algorithm. tion prospects.
In recent years, scholars have mainly made two improve- The rest of the paper is structured as follows: Section 2
ments to address the illumination variation problem in the reviews related works. Section 3 provides the methodology of
ORB algorithm: the first is to improve the calculation method the improved ORB algorithm. Experimental discussion and
of adaptive thresholds [17]–[19], and the second is to expand analysis are given in Section 4. Section 5 concludes the whole
the application scope of adaptive thresholds [20], [21]. work.
To address the problem of the unsuitability of the threshold
in the ORB algorithm for different image scenes, scholars II. RELATED WORK
have proposed adaptive threshold calculation methods based The ORB algorithm combines the FAST feature detection
on local pixel distribution, such as methods based on adaptive algorithm and the binary descriptor algorithm. Compared
truncation threshold [22], adaptive median [23] and adap- with other feature extraction algorithms, it not only has
tive statistics [24]. In addition, machine learning methods, higher accuracy, but also has a very fast processing speed,
such as SVM (Support vector machine, SVM) [25], CNN making it a practical and cost-effective algorithm.
(Convolutional neural networks, CNN) [26], have also been
proposed to predict adaptive thresholds, thereby improving
A. FAST FEATURE POINTS DETECTION
the robustness and adaptability of the ORB algorithm to
complex lighting conditions. The FAST algorithm depicted in Figure 1 initially selects a
However, these methods still have some limitations in central point within an image, and subsequently identifies
practical applications. For example, the adaptive threshold a continuous set of pixels within a fixed window area sur-
calculation based on the local pixel distribution is prone rounding the selected center point. The grayscale difference
to interference from noise and outliers, which may lead to between the central point and the continuous set of pixels is
false positives or false negatives. On the other hand, machine then calculated. If the grayscale difference of any pixel in the
learning-based adaptive threshold methods require a large set exceeds a pre-defined threshold, then the central point is
amount of training data and computational resources, and identified as a feature point.
have high requirements for data distribution and features,
which may not be practical in real-world applications.
The present study proposes an improved ORB feature
extraction algorithm based on enhanced image and truncated
adaptive threshold. Firstly, a Gaussian filter is applied for
noise reduction, and then the image is preprocessed using
truncated adaptive gamma brightness adjustment and unsharp
masking methods to improve the quality of the initial image.
Next, the image is segmented into multiple fixed-sized sub-
regions, and the corresponding thresholds are obtained using
an improved truncated adaptive OTUS method in each sub- FIGURE 1: Schematic diagram of FAST feature extraction
region. Finally, the improved ORB algorithm is used to algorithm.
extract feature points. This algorithm effectively solves the
problem of being unable to extract feature points in envi-
ronments with excessive or insufficient lighting, or a lower The specific steps of the original FAST feature extraction
number of extracted feature points, while ensuring real-time algorithm are as follows:
performance and robustness. Step 1: Select a pixel in the image as the center point fmid ,
The contributions of this paper are as follows: and record its grayscale value Imid .
1) An improved ORB feature extraction algorithm is pro- Step 2: Search for a region in the image by selecting N
posed, which combines image enhancement and truncated pixels within a neighborhood of radius R around the center
adaptive threshold methods to effectively solve the problem point fmid . Typically, R is set to 3 and N is set to 16.
of insufficient feature points extracted by ORB algorithm Step 3: Set a threshold T , usually at 10% of fmid .
under the influence of factors such as lighting changes, noise, Step 4: If K continuous pixels (empirical data shows that
and outliers. K = 9 usually gives the best results) among the N pixels
2) A method based on the improved truncated adaptive have the same brightness value (either brighter or darker),
OTUS method is proposed to calculate the threshold, which the point is considered a corner point. Otherwise, move
segments the image into multiple sub-regions for processing the center point and repeat steps 1-4 until all pixels in the
and can better adapt to various scenarios, thereby enhancing entire image have been processed. The mathematical model
the robustness and adaptability of the ORB algorithm. for determining whether a pixel is brighter or darker is as
3) Experiments are conducted on multiple datasets to follows:
2 VOLUME 4, 2022
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
VOLUME 4, 2022 3
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
where I(x, y) represents the mean of the pixel grayscale where I(x, y) represents the gray value of the original image,
values in the image. ∗ represents the result of the convolution operation, and
Step 3: Judge the size of the standard deviation λ of the h(m, n) represents the Gaussian convolution kernel.
pixel grayscale values in the image. If it is greater than 0.25,
the image quality is considered poor and proceeds to step 4; 2) Truncated adaptive gamma brightness adjustment
if it is less than 0.25, the image quality is considered good Inspired by reference [29], we improved the gamma correc-
and proceeds to step 5. tion algorithm in this paper to handle situations where the
Step 4: Judge the size of the mean pixel grayscale I(x, y) entire image is too dark or too bright. Assuming the total
value in the image. If it is less than 128, the image is number of pixels in an image is:
considered dark, and if it is greater than 128, the image is
considered bright, then set Ii (x, y) = 255 − Ii (x, y). Then n=M ·N (10)
perform Gaussian filtering to remove noise and adaptive where M and N represent the length and width of the
gamma adjustment to adjust brightness. image, and are both positive integers. The probability density
Step 5: Perform unsharp masking on the image. function for a grayscale level of i is given by:
ni
1) Gaussian filtering Pi = (11)
n
In order to eliminate Gaussian noise in the images, this paper
where ni represents the number of pixels with grayscale level
adopts the Gaussian filtering algorithm, which convolves the
i, and i is a natural number. The weighted probability density
image with a Gaussian kernel to achieve filtering operation.
function is given by:
The shape of the kernel conforms to the form of the Gaussian
distribution function. For each pixel in the image, the original
Pi − Pmin
α
grayscale value can be replaced by calculating the weighted Pwi = Pmax · (12)
Pmax − Pmin
average grayscale value of the surrounding neighborhood
pixels, thereby suppressing noise. The principle schematic where Pmax and Pmin represent the maximum and minimum
diagram of the Gaussian filtering algorithm is shown in values of Pi respectively, and α represents the smoothness
Figure 3. factor, which is usually set to 0.2. The weighted distribution
function of the image is given by:
i
X Pwi
Cwi = Pk (13)
h=0 i=0 Pwi
γi = 1 − Cwi (14)
Original image Filter kernel To prevent insignificant brightness enhancement, a trun-
cated gamma parameter is designed as:
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
Finally, the mask for contrast enhancement can be ex- that is, the probability density function of each sub-region
pressed as: is identical. If a separate grayscale level analysis is required
for each sub-region, the probability density function must be
Tmask (x, y) = I 0 (x, y) − f (x, y) (17) calculated separately for each sub-region.
For two types of pixel elements, C0 and C1 the probability
3) Unsharp masking of occurrence for each class is:
Unsharp masking is an image sharpening technique that
enhances the contours and details of an image by using a w0 = P (C0 )
low-pass filter to obtain a blurred image, creating a mask, t
X (22)
and combining it with the original image. Compared to = Pi
directly using sharpening convolution operators for image i=0
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
C = a · |Imid − t| (33)
where the fixed parameter a is usually set to 0.3 according
to experimental results. Imid represents the center pixel value
of a sub-region, and t represents the optimal classification
threshold.
To avoid extracting too many low-quality feature points
due to excessively small adaptive thresholds, this algorithm
adopts a strategy of adaptive truncation threshold: FIGURE 5: The improved ORB algorithm.
C 0 = max (C, Cmin ) (34) FIGURE 6: Illustration of feature point extraction compari-
son among different methods in frame 585.
where the fixed parameter Cmin is usually set to 7 according
to experimental results. TABLE 2: Comparison of feature point extraction perfor-
mance between original ORB algorithm and improved ORB
IV. DISCUSSION AND ANALYSIS
algorithm in the 585th frame
A. EXPERIMENTAL ENVIRONMENT
This experiment used a laptop computer running Ubuntu Method Original ORB Improved ORB
20.08 operating system, with an Intel (R) Core (TM) i7-
Extraction number / (pcs) 8357 11625
7700HQ processor with a frequency of 2.60GHZ and 8GB
Extraction time / (ms) 301.55 356.90
of RAM.
The original image is from the MH_01_easy open source
dataset in Euroc, which is a classic set of robot vision datasets
composed of image sequences captured during robot move- even detected (marked by red boxes). However, the improved
ment. Since the images in this dataset contain significant ORB algorithm, which combines image enhancement and
changes in brightness, it is particularly suitable for verifying truncated adaptive thresholding, can extract more accurate
the correctness and robustness of our algorithm. feature points in the same region. Moreover, according to
Table 2, the improved ORB algorithm extracts far more
B. PERFORMANCE COMPARISON feature points than the original algorithm, with an increase
After multiple experiments, the original algorithm used in in extraction time of only about 55ms.
this study adopts a fixed threshold of 20 for feature point To further evaluate the adaptability of the improved ORB
extraction, as it can extract more and more accurate feature algorithm to complex lighting changes, tests were conducted
points. The improved algorithm uses a parameter selection on images with gradually changing brightness, including
scheme with a sharpening degree of 1 and a mask degree of brightness changes ranging from aÀ30%,
˛ aÀ40%,
˛ to aÀ60%
˛
0.3. of the original image. Performance comparison was made
To ensure the universality of the experimental results, a with the original algorithm, as shown in Figure 9. The results
randomly selected image from the dataset was used for the showed that the improved ORB algorithm outperformed the
experiment. The results show that the improved ORB algo- original one, especially under extreme brightness changes,
rithm proposed in this paper has a significant improvement with a significant increase in the number of extracted feature
in the number of feature points extracted compared to the points.
original algorithm. As shown in Figure 7, the improved ORB algorithm
As shown in Figure 6, the original ORB algorithm extracts extracts feature points more steadily and smoothly as the
fewer feature points (marked by blue circles) in areas with brightness changes. The greater the magnitude of brightness
poor lighting, and some important feature points are not change, the more obvious the improvement in the number of
6 VOLUME 4, 2022
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
400
300
200 FIGURE 10: Comparison of the number of feature points
100 extracted from different methods in MH_01_easy data set.
0
-60 -40 -20 0 20 40 60
Brightness increase/%
algorithm to ORB-SLAM to improve localization accuracy.
FIGURE 8: Feature extraction time comparison
diagram. V. CONCLUSION
FIGURE 9: Comparison of feature extraction performance In this paper, an improved ORB feature extraction algorithm
among different methods under varying lighting conditions is proposed to achieve reliable feature point extraction in
in frame 585. complex lighting environments for real-time systems. The al-
gorithm first uses Gaussian filtering for denoising, truncation
adaptive gamma brightness adjustment, and unsharp masking
feature points extracted. As shown in Figure 8, the average to enhance the image, and proposes a method for obtaining
feature extraction time of the improved ORB algorithm is the truncation adaptive threshold based on the OTUS algo-
only about 50ms higher than that of the original algorithm. rithm. Compared with the original ORB feature extraction
Therefore, although the algorithm increases some running algorithm, this algorithm has stronger robustness, accuracy,
time, it ensures the real-time performance of the system and real-time performance, and can capture corresponding
within an acceptable range. feature points under adverse lighting conditions. Experimen-
From the analysis of Figure 6, it can be seen that com- tal results show that the proposed algorithm can increase
pared to the original algorithm, the proposed improved ORB the number of feature point extractions in complex lighting
feature extraction algorithm in this paper has increased the environments while maintaining a relatively stable extraction
number of feature points extracted in each frame, especially speed, and has a wide range of application prospects.
in environments with excessively dark or bright lighting
conditions, where the effect is particularly significant. ACKNOWLEDGMENT
Based on the results of the experiments, it can be con- The authors are grateful to the data sets which are open access
cluded that the proposed improved ORB feature extraction in Github.
algorithm in this paper has a significant improvement in the
number of extracted features in complex lighting environ- REFERENCES
ments and can meet the real-time requirements of the system. [1] Yinggang Xie, Quan Wang, Yuanxiong Chang, and Xueyuan Zhang. Fast
target recognition based on improved orb feature. Applied Sciences,
12(2):786, 2022.
C. FUTURE WORK [2] Libo Sun, Xiaokai Zhang, and Wenhu Qin. Research on target recognition
Due to the lack of outlier rejection in the experiment, there and tracking in mobile augmented reality assisted maintenance. Computer
were many incorrect feature correspondences before and Animation and Virtual Worlds, page e2112, 2022.
[3] Carlos Campos, Richard Elvira, Juan J Gómez Rodríguez, José MM
after the improvement. Additionally, no uniformization was Montiel, and Juan D Tardós. Orb-slam3: An accurate open-source library
applied, leading to clustering of some feature points. In for visual, visual–inertial, and multimap slam. IEEE Transactions on
future research, we will focus on improving the ORB fea- Robotics, 37(6):1874–1890, 2021.
[4] Andréa Macario Barros, Maugan Michel, Yoann Moline, Gwenolé Corre,
ture extraction algorithm by performing outlier rejection and and Frédérick Carrel. A comprehensive survey of visual slam algorithms.
uniformization processing. We will also apply the improved Robotics, 11(1):24, 2022.
VOLUME 4, 2022 7
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4
This article has been accepted for publication in IEEE Access. This is the author's version which has not been fully edited and
content may change prior to final publication. Citation information: DOI 10.1109/ACCESS.2023.3261665
[5] Jun Cheng, Liyan Zhang, Qihong Chen, Xinrong Hu, and Jingcao Cai. A [27] Ziyan Zhang, Lixiao Wang, Wenfeng Zheng, Lirong Yin, Rongrong Hu,
review of visual slam methods for autonomous driving vehicles. Engineer- and Bo Yang. Endoscope image mosaic based on pyramid orb. Biomedical
ing Applications of Artificial Intelligence, 114:104992, 2022. Signal Processing and Control, 71:103261, 2022.
[6] Dan Ma and Hui-cheng Lai. Remote sensing image matching based [28] Zhixu Dong, Xingwei Sun, Fangsu Xu, and Weijun Liu. A low-rank and
improved orb in nsct domain. Journal of the Indian Society of Remote sparse decomposition-based method of improving the accuracy of sub-
Sensing, 47:801–807, 2019. pixel grayscale centroid extraction for spot images. IEEE Sensors Journal,
[7] Chris Harris, Mike Stephens, et al. A combined corner and edge detector. 20(11):5845–5854, 2020.
In Alvey vision conference, volume 15, pages 10–5244. Citeseer, 1988. [29] Gang Cao, Lihui Huang, Huawei Tian, Xianglin Huang, Yongbin Wang,
[8] Jianbo Shi et al. Tomasi. good features to track. In 1994 Proceedings and Ruicong Zhi. Contrast enhancement of brightness-distorted images
of IEEE Conference on Computer Vision and Pattern Recognition, pages by improved adaptive gamma correction. Computers & Electrical Engi-
593–600. sn, 1994. neering, 66:569–582, 2018.
[9] G Lowe. Sift-the scale invariant feature transform. Int. J, 2(91-110):2,
2004.
[10] Edward Rosten and Tom Drummond. Machine learning for high-speed
corner detection. In Computer Vision–ECCV 2006: 9th European Con-
ference on Computer Vision, Graz, Austria, May 7-13, 2006. Proceedings,
Part I 9, pages 430–443. Springer, 2006.
[11] Herbert Bay, Tinne Tuytelaars, and Luc Van Gool. Surf: Speeded up robust
features. Lecture notes in computer science, 3951:404–417, 2006.
[12] Ethan Rublee, Vincent Rabaud, Kurt Konolige, and Gary Bradski. Orb:
An efficient alternative to sift or surf. In 2011 International conference on
computer vision, pages 2564–2571. Ieee, 2011.
[13] Stefan Leutenegger, Margarita Chli, and Roland Y Siegwart. Brisk: Binary
robust invariant scalable keypoints. In 2011 International conference on
computer vision, pages 2548–2555. Ieee, 2011. YONG DAI received his M.S. degree in control
[14] Edgar Simo-Serra, Eduard Trulls, Luis Ferraz, Iasonas Kokkinos, Pascal science and engineering from the University of
Fua, and Francesc Moreno-Noguer. Discriminative learning of deep Science and Technology Liaoning, Anshan, in
convolutional feature point descriptors. In Proceedings of the IEEE 2016. He received his Ph.D. degree in control
international conference on computer vision, pages 118–126, 2015. theory and control engineering from the College
[15] Xufeng Han, Thomas Leung, Yangqing Jia, Rahul Sukthankar, and of Marine Electrical Engineering, Dalian Maritime
Alexander C Berg. Matchnet: Unifying feature and metric learning
University, Dalian, in 2020. Since April 2021, he
for patch-based matching. In Proceedings of the IEEE conference on
has been an Associate Professor in the School of
computer vision and pattern recognition, pages 3279–3286, 2015.
Automation and Electrical Engineering, Shenyang
[16] Jie Tang, Fei-Peng Tian, Wei Feng, Jian Li, and Ping Tan. Learning guided
convolutional network for depth completion. IEEE Transactions on Image Ligong University, Shenyang. His research inter-
Processing, 30:1116–1129, 2020. ests include robotic nonlinear control theory and applications, navigation,
[17] Chuanping Geng, Junjie Yang, Jinchen Lin, Ting Yu, and Kexin Shi. simultaneous localization and mapping (SLAM) and self-driving intelligent
An improved orb feature extraction algorithm. In journal of physics: vehicle system.
conference series, volume 1616, page 012026. IOP Publishing, 2020.
[18] Wu Guangyun and Zhou Zhiping. An improved orb feature extraction
and matching algorithm. In 2021 33rd Chinese Control and Decision
Conference (CCDC), pages 7289–7292. IEEE, 2021.
[19] Shaoshao Wang, Aihua Zhang, and Han Wang. A feature extraction
algorithm for enhancing graphical local adaptive threshold. In Intelligent
Computing Theories and Application: 18th International Conference, ICIC
2022, Xi’an, China, August 7–11, 2022, Proceedings, Part I, pages 277–
291. Springer, 2022.
[20] Qiuyu Zang, Kehua Zhang, Ling Wang, and Lintong Wu. An adaptive orb-
slam3 system for outdoor dynamic environments. Sensors, 23(3):1359,
2023.
[21] Renjie Wu, Matthew Pike, and Boon-Giin Lee. Dt-slam: dynamic thresh-
olding based corner point extraction in slam system. IEEE Access, JIAXIN WU received the B.E degree in Inter-
9:91723–91729, 2021. net of Things Engineering from Henan University
[22] Leijian Yu, Erfu Yang, and Beiya Yang. Afe-orb-slam: robust monoc- of Technology, Zhengzhou, China in 2021. He
ular vslam based on adaptive fast threshold and image enhancement for is currently pursuing the masteraŕs
˛ degree with
complex lighting environments. Journal of Intelligent & Robotic Systems, School of Automation and Electrical Engineering,
105(2):26, 2022. Shenyang Ligong University, Shenyang. China.
[23] Shiji Li, Qing Wang, and Jiayue Li. Improved orb matching algorithm His current research interests include robotic si-
based on adaptive threshold. In Journal of Physics: Conference Series, multaneous localization and mapping (SLAM),
volume 1871, page 012151. IOP Publishing, 2021. navigation and applications.
[24] Bin Nan, Yinghui Wang, Yanxing Liang, Min Wu, Pengjiang Qian, and
Gang Lin. Ad-rms: Adaptive regional motion statistics for feature match-
ing filtering. In Advances in Computer Graphics: 39th Computer Graphics
International Conference, CGI 2022, Virtual Event, September 12–16,
2022, Proceedings, pages 129–141. Springer, 2023.
[25] Faisal Dharma Adhinata and Agus Harjoko. Object searching on video
using orb descriptor and support vector machine. In Advances in Com-
putational Collective Intelligence: 12th International Conference, ICCCI
2020, Da Nang, Vietnam, November 30–December 3, 2020, Proceedings
12, pages 239–251. Springer, 2020.
[26] Gorla Babu and Pinjari Abdul Khayum. Elephant herding with whale
optimization enabled orb features and cnn for iris recognition. Multimedia
Tools and Applications, 81(4):5761–5794, 2022.
8 VOLUME 4, 2022
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License. For more information, see https://creativecommons.org/licenses/by-nc-nd/4