[go: up one dir, main page]

RU2367019C2 - Method for digital image interpolation - Google Patents

Method for digital image interpolation Download PDF

Info

Publication number
RU2367019C2
RU2367019C2 RU2007105236/09A RU2007105236A RU2367019C2 RU 2367019 C2 RU2367019 C2 RU 2367019C2 RU 2007105236/09 A RU2007105236/09 A RU 2007105236/09A RU 2007105236 A RU2007105236 A RU 2007105236A RU 2367019 C2 RU2367019 C2 RU 2367019C2
Authority
RU
Russia
Prior art keywords
image
polynomial
interpolation
degree
coefficients
Prior art date
Application number
RU2007105236/09A
Other languages
Russian (ru)
Other versions
RU2007105236A (en
Inventor
Виталий Николаевич Бурсук (RU)
Виталий Николаевич Бурсук
Original Assignee
Корпорация "САМСУНГ ЭЛЕКТРОНИКС Ко., Лтд."
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Корпорация "САМСУНГ ЭЛЕКТРОНИКС Ко., Лтд." filed Critical Корпорация "САМСУНГ ЭЛЕКТРОНИКС Ко., Лтд."
Priority to RU2007105236/09A priority Critical patent/RU2367019C2/en
Publication of RU2007105236A publication Critical patent/RU2007105236A/en
Application granted granted Critical
Publication of RU2367019C2 publication Critical patent/RU2367019C2/en

Links

Images

Landscapes

  • Image Processing (AREA)
  • Editing Of Facsimile Originals (AREA)

Abstract

FIELD: physics; image processing.
SUBSTANCE: invention relates to processing digital images, particularly to methods of changing the scale of a digital image, i.e. calculating luminance values in points, which do not belong to the initial set of points in which luminance values are known. A method is proposed for interpolation of a digital image with increase in sampling frequency by t times, comprising the following stages: pre-processing the image; determining the viewing window size m, degree of interpolation function n and scaling factor t; coefficient vector K is calculated, which corresponds to the given m, n, t combination; for each pixel of the initial image, m-1 nearest neighbours are determined, which, together with that pixel, form the viewing window, m; luminance of pixels, which form the viewing window m, are standardised to the k (k=1) level; luminance t2 of pixels is calculated using an m-dimensional interpolation polynomial of degree n, with vector K as coefficients; each interpolated pixel is assigned new coordinates (x', y); all previous steps are repeated for each colour component; the image is post-processed to reduce defects.
EFFECT: design of a linear spatial interpolation method, with improved capabilities and considerably less artefacts.
6 cl, 13 dwg

Description

Изобретение относится к методам обработки цифровых изображений. В частности, к методам изменения размеров (масштаба) цифрового изображения, т.е. вычислению значений яркости в точках, не принадлежащих изначально исходному множеству точек, в которых значения яркости известны.The invention relates to digital image processing methods. In particular, to methods for changing the size (scale) of a digital image, i.e. calculating brightness values at points that do not originally belong to the original set of points at which brightness values are known.

Существует большое разнообразие различных методов интерполяции. Все эти методы можно классифицировать по точности, критериям качества, мере приближения и применяемому математическому аппарату. В основе большинства алгоритмов интерполяции растрового изображения лежит замена неизвестной функции двумерного распределения яркости интерполируемого изображения функцией, близкой к неизвестной и обладающей свойствами, позволяющими легко производить те или иные аналитические или вычислительные операции. При этом в зависимости от выбора класса интерполирующих функций решение задачи интерполяции сводится к решению систем линейных или нелинейных уравнений.There is a wide variety of different interpolation methods. All these methods can be classified according to accuracy, quality criteria, approximation and the mathematical apparatus used. Most bitmap interpolation algorithms are based on replacing the unknown function of the two-dimensional brightness distribution of the interpolated image with a function close to the unknown and having properties that make it easy to perform certain analytical or computational operations. Moreover, depending on the choice of the class of interpolating functions, the solution to the interpolation problem is reduced to solving systems of linear or nonlinear equations.

Линейные методы исключительно важны для обработки изображений, поскольку они опираются на значительную совокупность хорошо изученных теоретических и практических результатов (см. патенты США № 5,671,298 [1], № 6,320,593 [2], № 6,496,609 [3], United States Patent 6965705 [4]).Linear methods are extremely important for image processing, since they rely on a significant body of well-studied theoretical and practical results (see US Pat. No. 5,671,298 [1], No. 6,320,593 [2], No. 6,496,609 [3], United States Patent 6965705 [4] )

Нелинейные методы (см. патент США № 6,823,091 [5]), хотя иногда и приводят к лучшим результатам, однако они не всегда предсказуемы, однозначны и по большей части недостаточно исследованы теоретически. Также существенным недостатком нелинейных методов по сравнению с линейными является повышенные требования к вычислительным ресурсам и низкая скорость интерполирования.Nonlinear methods (see US Patent No. 6,823,091 [5]), although sometimes lead to better results, are not always predictable, unambiguous, and for the most part insufficiently studied theoretically. Also, a significant drawback of nonlinear methods compared to linear ones is the increased requirements for computing resources and low interpolation speed.

Дальнейшим развитием нелинейных методов интерполяции является применение адаптивных алгоритмов (см., например, патенты США № 5,532,950 [6], № 6,191,788 [7]), поведение которых изменяется в зависимости от статических свойств изображения внутри области действия интерполирующей функции. Как показывает практика, эффективность работы более сложных с вычислительной точки зрения адаптивных алгоритмов обычно лучше, чем у ранее рассмотренных методов, однако повышенные вычислительные требования при реализации адаптивных методов несмотря на высокую эффективность несколько снижают их область применения.A further development of nonlinear interpolation methods is the use of adaptive algorithms (see, for example, US Pat. Nos. 5,532,950 [6], 6,191,788 [7]), the behavior of which varies depending on the static properties of the image within the scope of the interpolating function. As practice shows, the performance of more computationally adaptive algorithms is usually better than the methods previously considered, however, increased computational requirements for the implementation of adaptive methods, despite their high efficiency, slightly reduce their scope.

Из всех методов наиболее близкими к заявленному изобретению являются методы, основанные на линейной пространственной интерполяции. В качестве прототипа заявленного изобретения был выбран способ линейной кубической интерполяции, описанный в патенте США № 5,671,298 [8].Of all the methods closest to the claimed invention are methods based on linear spatial interpolation. As a prototype of the claimed invention, the linear cubic interpolation method described in US Pat. No. 5,671,298 [8] was selected.

Интерполяция кубическими сплайнами заключается в поиске таких полиномов третьей степени на каждом из отрезков (границы которых являются соседними точками), у которых первая и вторая производные совпадают с первой и второй производной соседнего полинома. Таким образом, получающаяся непрерывная кусочно-полиномиальная функция обладает непрерывными первой и второй производной.Interpolation with cubic splines consists in the search for such polynomials of the third degree on each of the segments (whose boundaries are adjacent points) whose first and second derivatives coincide with the first and second derivatives of the neighboring polynomial. Thus, the resulting continuous piecewise polynomial function has continuous first and second derivatives.

Существенным недостатком метода интерполяции, описанного в прототипе [8], является наличие характерных артефактов в интерполируемом изображении, ухудшающих точность масштабирования в области резких изменений яркости. Типичные артефакты включают в себя появление эффекта зубчатого края на наклонных линиях, размытие из-за ограничений при восстановлении высокочастотных составляющих интерполируемых данных, и эффект Гиббса, проявляющийся в виде паразитных волнообразных колебаний интерполяционной функции, отсутствующих у интерполируемого изображения.A significant drawback of the interpolation method described in the prototype [8] is the presence of characteristic artifacts in the interpolated image that degrade the accuracy of scaling in the region of sharp changes in brightness. Typical artifacts include the appearance of a serrated edge effect on slanted lines, blur due to limitations in the recovery of high-frequency components of the interpolated data, and the Gibbs effect, which manifests itself as spurious wave-like oscillations of the interpolation function that are absent in the interpolated image.

Техническая задача, на решение которой направлено заявляемое изобретение, заключается в создании линейного пространственного метода интерполяции с улучшенными интерполяционными возможностями и со значительно меньшими артефактами, свойственными обычным линейным интерполяционным алгоритмам.The technical problem to which the claimed invention is directed is to create a linear spatial interpolation method with improved interpolation capabilities and with much smaller artifacts characteristic of conventional linear interpolation algorithms.

Поставленная задача решена путем разработки способа интерполяции изображения с увеличением частоты дискретизации цифрового изображения в t раз, состоящего из следующих шагов:The problem is solved by developing a method of image interpolation with increasing the sampling frequency of a digital image by t times, consisting of the following steps:

- осуществляют предварительную обработку изображения;- carry out preliminary image processing;

- определяют размер окна визирования m, степень интерполяционной функции n и масштабный коэффициент t;- determine the size of the window of sight m, the degree of the interpolation function n and the scale factor t;

- считывают вектор коэффициентов K, соответствующий заданной комбинации m, n, t;- read the vector of coefficients K corresponding to a given combination of m, n, t;

- определяют для каждого пикселя исходного изображения m-1 ближайших соседей, которые вместе с этим пикселем образуют окно визирования m;- determine for each pixel of the original image m-1 the nearest neighbors, which together with this pixel form a window of sight m;

- осуществляют нормировку яркости пикселей, образующих окно визирования m до уровня k (k=1);- carry out the normalization of the brightness of the pixels forming the viewing window m to the level k (k = 1);

- рассчитывают яркость t2 пикселей с помощью m мерного интерполяционного полинома степени n, имеющего вектор K в качестве коэффициентов;- calculate the brightness of t 2 pixels using m dimensional interpolation polynomial of degree n having the vector K as coefficients;

- присваивают каждому интерполированному пикселю новые координаты (x', y');- assign to each interpolated pixel new coordinates (x ', y');

- повторяют все предыдущие шаги для каждой цветовой компоненты;- repeat all the previous steps for each color component;

- проводят заключительную обработку изображения для уменьшения артефактов.- spend the final processing of the image to reduce artifacts.

Таким образом, решение сводится к созданию линейного пространственного интерполианта на основе многомерного кусочно-непрерывного алгебраического многочлена (полиномиального сплайна). Размерность и степень многочлена выбираются исходя из требований точности восстановления сигнала и вычислительных возможностей.Thus, the solution reduces to creating a linear spatial interpoliant based on a multidimensional piecewise continuous algebraic polynomial (polynomial spline). The dimension and degree of the polynomial are selected based on the requirements of the accuracy of signal reconstruction and computational capabilities.

Для функционирования полиномиального сплайна, отвечающего поставленной задаче, необходимо найти такие коэффициенты полинома, которые будут оптимально удовлетворять условию достижения максимальной точности интерполяционной функцииFor the functioning of the polynomial spline corresponding to the task, it is necessary to find such coefficients of the polynomial that will optimally satisfy the condition for achieving maximum accuracy of the interpolation function

Способ по п.1 отличется тем, что коэффициенты определяют с применением множественного регрессионного анализа и набора эталонных изображений, которые искажены по тому же алгоритму, что и обрабатываемое изображение.The method according to claim 1, characterized in that the coefficients are determined using multiple regression analysis and a set of reference images that are distorted by the same algorithm as the processed image.

Их количество и вид выбирается исходя из выполнения условия достижения заданной точности интерполяционной функции. В общем случае для получения хороших результатов в качестве эталона достаточно использовать любое изображение с максимально широким диапазоном изменений локальных контрастов, однако наилучший результат с точки зрения минимизации погрешности интерполирования достигается только в случае рационального (репрезентативного) подбора эталонов.Their number and type is selected based on the fulfillment of the condition for achieving the specified accuracy of the interpolation function. In the general case, to obtain good results, it is sufficient to use any image with the widest possible range of changes in local contrasts as a reference, however, the best result from the point of view of minimizing the interpolation error is achieved only in the case of a rational (representative) selection of standards.

Техническим результатом заявленного изобретения является создание линейного пространственного интерполяционного полинома путем реализации ряда модификаций метода интерполяции, описанного в прототипе. Указанные модификации базируются на следующих заключениях.The technical result of the claimed invention is the creation of a linear spatial interpolation polynomial by implementing a number of modifications of the interpolation method described in the prototype. These modifications are based on the following conclusions.

В основе бикубического метода лежит приближение многомерной интерполяционной функцией 3 степени в пределах окна 4×4 точек. Решая задачу определения значения интерполированного пикселя, после недолгих математических преобразований можно получить результирующее выражение, которое определяется как сумма значений 16 соседних интерполируемых пикселей, умноженных на соответствующие их расположению весовые коэффициенты аij.The bicubic method is based on the approximation of a multidimensional interpolation function of degree 3 within a window of 4 × 4 points. Solving the problem of determining the value of the interpolated pixel, after some mathematical transformations, you can get the resulting expression, which is defined as the sum of the values of 16 neighboring interpolated pixels, multiplied by the weight coefficients a ij corresponding to their location.

Figure 00000001
Figure 00000001

Весовые коэффициенты aij для бикубического метода не зависят от значений функции f(xi, yi) и однозначно вычисляются исходя из соблюдения условий непрерывности внутри интервала самой интерполяционной функции, ее первой и второй производных и заданных значений первой или второй производной на границах интервала. Очевидно, что с математической точки зрения выражение (*) можно определить и как 16 мерный полином первой степени, в котором мономами являются значения яркости 16 соседних интерполируемых пикселей. Интересным является и тот факт, что как в случае использования интерполирующей функции любой другой степени, так и в случае более или менее жестких накладываемых условий вид выражения (*) остается неизменным, а все возможные варианты будут реализовываться только через весовые коэффициенты aij.The weighting coefficients a ij for the bicubic method are independent of the values of the function f (x i , y i ) and are uniquely calculated on the basis of observing the continuity conditions within the interval of the interpolation function itself, its first and second derivatives and the given values of the first or second derivative at the boundaries of the interval. Obviously, from a mathematical point of view, expression (*) can also be defined as a 16-dimensional polynomial of the first degree, in which the brightness values of 16 neighboring interpolated pixels are monomials. An interesting fact is that both in the case of using an interpolating function of any other degree and in the case of more or less severe imposed conditions, the form of the expression (*) remains unchanged, and all possible options will be realized only through weighting factors a ij .

Предлагаемый метод является обобщением бикубического метода и дальнейшим его развитием, что выражается в следующих изменениях:The proposed method is a generalization of the bicubic method and its further development, which is expressed in the following changes:

1. Количество учитываемых соседних интерполируемых пикселей уже не ограничивается 16, а может принимать любые значения.1. The number of taken into account neighboring interpolated pixels is no longer limited to 16, but can take any values.

2. Степень полинома уже не ограничивается первой, а может принимать любые другие целые и неотрицательные значения.2. The degree of the polynomial is no longer limited to the first, but can take any other integer and non-negative values.

3. Коэффициенты аij определяются только условием обеспечения минимальной ошибки, и никакие другие условия (гладкости, например) не накладываются. При этом для их нахождения решается задача на основе метода множественного регрессионного анализа.3. The coefficients a ij are determined only by the condition for ensuring a minimum error, and no other conditions (smoothness, for example) are imposed. Moreover, to find them, the problem is solved on the basis of the multiple regression analysis method.

При этом становится очевидным, что предлагаемый метод не решает задачу нахождения интерполяционной функции. Поэтому данным методом нельзя воспользоваться в случае решения задач по нахождению функциональной зависимости. Наиболее важным и положительным свойством предлагаемого метода является сбалансированное сочетание таких качеств, как высокая скорость вычисления, которая свойственна обычным линейным методам, и высокое качество интерполирования, которое свойственно ресурсоемким нелинейным адаптивным методам.Moreover, it becomes obvious that the proposed method does not solve the problem of finding the interpolation function. Therefore, this method cannot be used in the case of solving problems of finding a functional dependence. The most important and positive property of the proposed method is a balanced combination of qualities such as high computation speed, which is typical of conventional linear methods, and high quality interpolation, which is characteristic of resource-intensive nonlinear adaptive methods.

Наиболее часто при решении задач масштабирования изображений используют различные алгоритмы интерполирования. Результатом работы таких алгоритмов является восстановленная с некоторой погрешностью свертка искомого изображения с масштабным окном. Для улучшения визуального качества часто используют различные алгоритмы, повышающие резкость. В результате из-за накопления ошибок результат работы таких методов несовершенен, а временные затраты существенны. Отличительной особенностью предложенного метода является то, что он базируется на решении обратной некорректной задачи и его работа аналогична инверсному фильтру. Существуют современные методы масштабирования, которые решают данную задачу схожим образом, используя, например, алгоритмы обратной свертки (деконволюции) с применением различных процедур регуляризации. Однако впервые для решения таких задач был применен многомерный кусочно-непрерывный многомерный алгебраический многочлен. В отличие от наиболее распространенных алгоритмов, в основе которых лежит поиск неизвестной функции двумерного распределения яркости интерполируемого изображения, в предлагаемом методе целью является нахождение закона изменения яркости интерполированного пикселя.Most often, when solving image scaling problems, various interpolation algorithms are used. The result of the work of such algorithms is the convolution of the desired image with a large-scale window restored with some error. To improve visual quality, various sharpening algorithms are often used. As a result, due to the accumulation of errors, the result of the work of such methods is imperfect, and the time costs are significant. A distinctive feature of the proposed method is that it is based on solving an inverse incorrect problem and its operation is similar to an inverse filter. There are modern scaling methods that solve this problem in a similar way, using, for example, back-convolution (deconvolution) algorithms using various regularization procedures. However, for the first time, a multidimensional piecewise continuous multidimensional algebraic polynomial was used to solve such problems. Unlike the most common algorithms, which are based on the search for an unknown function of the two-dimensional distribution of brightness of an interpolated image, the proposed method aims to find the law of change in brightness of an interpolated pixel.

Для лучшего понимания существа заявляемого изобретения далее приводится его подробное описание с привлечением графических материалов.For a better understanding of the essence of the claimed invention the following is a detailed description with the use of graphic materials.

Фиг.1. Блок-схема базовых компонентов системы.Figure 1. The block diagram of the basic components of the system.

Фиг.2. Иллюстрация задачи интерполирования элементарного пикселя изображения.Figure 2. Illustration of the task of interpolating an elementary pixel of an image.

Фиг.3. Блок-схема этапов процесса расчета оптимальных коэффициентов полинома.Figure 3. The block diagram of the steps in the process of calculating the optimal polynomial coefficients.

Фиг.4. Блок-схема этапов процесса интерполяции изображения.Figure 4. A block diagram of the steps of an image interpolation process.

Фиг.5. Примеры работы алгоритма.Figure 5. Examples of the algorithm.

Способ интерполяции изображения, то есть увеличение частоты дискретизации цифрового изображения в t раз, работает следующим образом:The image interpolation method, that is, increasing the sampling frequency of a digital image by a factor of t, works as follows:

1. Осуществляют предварительную обработку изображения, если необходимо;1. Perform preliminary image processing, if necessary;

2. Задают размер окна m, степень интерполяционной функции n и масштабный коэффициент t;2. Set the window size m, the degree of the interpolation function n, and the scale factor t;

3. Загружают вектор коэффициентов K, соответствующий заданной комбинации m, n, t.3. Download the vector of coefficients K corresponding to a given combination of m, n, t.

4. Для каждого пикселя исходного изображения определяют m-1 ближайших соседей, которые вместе с этим пикселем образуют окно визирования m;4. For each pixel of the source image, m-1 nearest neighbors are determined, which together with this pixel form a sighting window m;

5. Нормируют яркость пикселей, образующих окно визирования, до уровня k (k=1);5. Normalize the brightness of the pixels forming the window of sight, to the level k (k = 1);

6. Рассчитывают яркости t2 пикселей с помощью m-мерного интерполяционного полинома степени n, имеющего вектор К в качестве коэффициентов;6. Calculate the brightness t 2 pixels using the m-dimensional interpolation polynomial of degree n having the vector K as coefficients;

7. Каждому интерполированному пикселю присваивают новые координаты (x', y');7. Each interpolated pixel is assigned a new coordinate (x ', y');

8. Повторяют шаги 4-7 для каждой цветовой компоненты;8. Repeat steps 4-7 for each color component;

9. В случае необходимости производят последующую обработку изображения для уменьшения артефактов.9. If necessary, perform subsequent image processing to reduce artifacts.

Метод может быть применен как к цветным, так и к черно-белым (с оттенками серого) изображениям и обеспечивает получение качественных и резких изображений с высоким пространственным разрешением.The method can be applied to both color and black and white (with shades of gray) images and provides high-quality and sharp images with high spatial resolution.

Фиг.1. показывает основные компоненты системы, на которой данный метод может быть реализован. Реализацией способа управляют с помощью процессора 101, который выполняет программный код, хранящийся в памяти 102. Также в памяти 102 хранят исходную черно-белую или цветную фотографию. Изображение анализируют, создают новое изображение, пиксели которого вычисляют с помощью пикселей исходного изображения. Новое изображение передают на устройство отображения 104, или на устройство печати 103. Передачу информации в системе осуществляют по шине данных 106.Figure 1. shows the main components of the system on which this method can be implemented. The implementation of the method is controlled by a processor 101 that executes program code stored in the memory 102. Also, the original black-and-white or color photograph is stored in the memory 102. The image is analyzed, a new image is created, the pixels of which are calculated using the pixels of the original image. The new image is transmitted to a display device 104, or to a printing device 103. Information is transmitted in the system via a data bus 106.

Далее описывается процесс создания интерполированного изображения.The following describes the process of creating an interpolated image.

Фиг.2. иллюстрирует задачу интерполирования изображения, где 2.1 и 2.2 - понижение дискретизации (downsampling), a 2.3 - повышение дискретизации (upsampling).Figure 2. illustrates the problem of image interpolation, where 2.1 and 2.2 are downsampling, and 2.3 is upsampling.

Пусть имеется изображение I(x, y), где x∈[1, xmax] y∈[1, ymax], которое было получено из Х после уменьшения (downsampling) известным способом в t раз. Несмотря на большое разнообразие допустимых способов уменьшения размеров изображений далее в качестве примера будет рассмотрен способ средних значений:Let there be an image I (x, y), where x∈ [1, x max ] y∈ [1, y max ], which was obtained from X after downsampling in a known manner t times. Despite the wide variety of acceptable methods for reducing image sizes, an average method will be considered below as an example:

Figure 00000002
,
Figure 00000002
,

Тогда задача качественной интерполяции (upsampling) формулируется следующим образом. По имеющемуся изображению I, требуется получить такое изображение

Figure 00000003
, которое бы согласно выбранному критерию близости в максимальной степени было близко к восстанавливаемому изображению X. Несмотря на возможность применения большого множества различных критериев близости в заявляемом способе предлагается использовать наиболее простой и самый распространенный критерий - метод наименьших квадратов (МНК):Then the problem of qualitative interpolation (upsampling) is formulated as follows. According to the available image I, it is required to obtain such an image
Figure 00000003
which, according to the selected proximity criterion, would be as close as possible to the reconstructed image X. Despite the possibility of applying a large number of different proximity criteria, the proposed method proposes to use the simplest and most common criterion - the least squares method (least squares):

Figure 00000004
,
Figure 00000004
,

Основой описываемого алгоритма является метод множественного регрессионного анализа с применением m мерного кусочно-непрерывного полинома степени n с фиксированными коэффициентами К вида:The basis of the described algorithm is the method of multiple regression analysis using m dimensional piecewise continuous polynomial of degree n with fixed coefficients K of the form:

Figure 00000005
, при этом
Figure 00000006
,
Figure 00000005
, wherein
Figure 00000006
,

где:

Figure 00000007
- m мерный полином степени n.Where:
Figure 00000007
- m dimensional polynomial of degree n.

ν1, ν2, …νw образуют вектор V, вид которого определяется данным полиномом.ν 1 , ν 2 , ... ν w form the vector V, the form of which is determined by this polynomial.

k1, k2, …kw образуют вектор K - коэффициенты полинома.k 1 , k 2 , ... k w form the vector K - coefficients of the polynomial.

Figure 00000008
- Приведенные к единому масштабу элементы изображения, принадлежащие оконной выборке, размер которой определяется параметром m. Ii∈[0, 1]
Figure 00000008
- Reduced to a single scale image elements belonging to the window selection, the size of which is determined by the parameter m. I i ∈ [0, 1]

d(x,y) - Масштабный коэффициент для текущего окна.d (x, y) - Scale factor for the current window.

I(x,y) - Интерполируемый пиксель изображения.I (x, y) - Interpolated image pixel.

Для каждого пикселя исходного изображения I(x,y) производят следующую процедуру: Выделяют m-1 ближайших соседей обрабатываемой точки I(x,y), которые образуют окно визирования m. После чего значения яркости внутри окна визирования приводят к единому масштабу нормировкой каждой переменной на диапазон разброса значений яркости внутри окна. В простейшем варианте это - линейное преобразование в единичный отрезок:For each pixel of the original image I (x, y) , the following procedure is performed: m-1 of the nearest neighbors of the processed point I (x, y) are selected, which form the sighting window m. After that, the brightness values inside the sighting window lead to a single scale by normalizing each variable to the range of variation of the brightness values inside the window. In the simplest version, this is a linear conversion to a unit segment:

Figure 00000009
,
Figure 00000009
,

при этом: di=Ii,max-Ii,min,wherein: d i = I i, max -I i, min ,

где: Ii,max, и Ii,max - максимальное и минимальное значения яркости пикселей в заданном окне.where: I i, max , and I i, max - the maximum and minimum values of the brightness of pixels in a given window.

Длина w векторов V и K определяют по следующей формуле:The length w of the vectors V and K is determined by the following formula:

Figure 00000010
,
Figure 00000010
,

Для нахождения вектора коэффициентов полинома методом МНК необходимо для каждого интерполируемого пикселя решить переопределенную систему линейных уравнений вида:To find the coefficient vector of the polynomial by the OLS method, it is necessary for each interpolated pixel to solve an overdetermined system of linear equations of the form:

Figure 00000011
, где
Figure 00000011
where

Figure 00000012
,
Figure 00000013
,
Figure 00000014
Figure 00000012
,
Figure 00000013
,
Figure 00000014

Где S - матрица коэффициентов системы линейных уравнений размером [w, w].Where S is the matrix of coefficients of a system of linear equations of size [w, w].

U - вектор правой части системы уравнений размером [w].U is the vector of the right side of the system of equations of size [w].

K - вектор коэффициентов полинома размером [w].K is the coefficient vector of a polynomial of size [w].

Коэффициенты матрицы S, U определяют по следующим формулам:The coefficients of the matrix S, U are determined by the following formulas:

Figure 00000015
Figure 00000015

Где r - число измерений:

Figure 00000016
Where r is the number of measurements:
Figure 00000016

В случае m=9, n=2 и t=4 переменные аi и bi определяют следующими выражениями:In the case of m = 9, n = 2 and t = 4, the variables a i and b i are determined by the following expressions:

Figure 00000017
Figure 00000017

Элементарное окно для каждого пикселя исходного изображения I(x, y) для случая m=9 задают следующими формулами:The elementary window for each pixel of the original image I (x, y) for the case m = 9 is defined by the following formulas:

I1=I(x-1, y-1); I2=I(x, y-1); I3=I(x+1, y-1);I 1 = I (x-1, y-1); I 2 = I (x, y-1); I 3 = I (x + 1, y-1);

I4=I(x-1, y); I5=I(x, y); I6=I(x+1, y);I 4 = I (x-1, y); I 5 = I (x, y); I 6 = I (x + 1, y);

I7=I(x-1, y+1); I8=I(x, y+1); I9=I(x+1, y+1);I 7 = I (x-1, y + 1); I 8 = I (x, y + 1); I 9 = I (x + 1, y + 1);

При этом x∈[2, xmax-1] и y∈[2, ymax-1]Moreover, x∈ [2, x max -1] and y∈ [2, y max -1]

После этого решают систему (1), каким-либо методом для однозначно определенных линейных систем, в частности, учитывающим симметрию СЛАУ. Решением системы является искомый вектор коэффициентов K.After that, system (1) is solved by some method for uniquely defined linear systems, in particular, taking into account the symmetry of SLAEs. The solution to the system is the desired vector of coefficients K.

Решения линейных систем уравнений большой размерности, как правило, является нетривиальной задачей по причине плохой их обусловленности. Система хорошо решается до тех пор, пока на погрешность алгоритма ее решения не начинает влиять вычислительная погрешность, которая неизбежна при любых компьютерных расчетах. Для получения достоверных результатов решения систем требуется использовать специальные методы, уменьшающие число обусловленности. Поскольку обусловленность системы прямо пропорционально ее размерности, выбор степени приближающего полинома и его размерности является важной задачей, которая сопряжена с определением таких оптимальных значений, при которых погрешность интерполяции минимальна, а вычислительные затраты приемлемы.The solution of linear systems of equations of large dimension, as a rule, is a non-trivial task due to their poor conditionality. The system is well solved until the computational error, which is inevitable in any computer calculations, begins to influence the error of the algorithm for solving it. To obtain reliable results of solving systems, it is required to use special methods that reduce the number of conditionality. Since the conditionality of the system is directly proportional to its dimension, the choice of the degree of the approximating polynomial and its dimension is an important task, which involves determining such optimal values for which the interpolation error is minimal and the computational cost is acceptable.

На Фиг.3 приведена блок-схема этапов реализация способа нахождения вектора оптимальных коэффициентов К для случая m=9, t=2, n=2.Figure 3 shows the block diagram of the steps implementing the method of finding the vector of optimal coefficients K for the case m = 9, t = 2, n = 2.

Вначале необходимо задать масштабный коэффициент интерполяции t, а также в зависимости от требуемой точности и вычислительных возможностей необходимо определить степень (n) и размерность (m) применяемого интерполяционного полинома, 301.First, it is necessary to set the scale interpolation coefficient t, and also depending on the required accuracy and computational capabilities, it is necessary to determine the degree (n) and dimension (m) of the applied interpolation polynomial, 301.

После этого необходимо выбрать эталонное изображение X, удовлетворяющее требованию получения минимальной погрешности интерполяции и определить (или задать) масштабирующую передаточную функцию (например, способ средних значений), 301.After that, it is necessary to select a reference image X that satisfies the requirement of obtaining a minimum interpolation error and determine (or set) a scaling transfer function (for example, the method of average values), 301.

Затем производят операцию уменьшения эталонного изображения X в t раз известным способом, определенным масштабирующей функцией, 302. В результате после уменьшения изображения X получают изображения I.Then, the operation of reducing the reference image X by t times in a known manner determined by the scaling function 302 is performed. As a result, after reducing the image X, images I.

Затем для каждой точки исходного изображения I(x, y), 303 производят следующую процедуру:Then, for each point of the original image I (x, y), 303, the following procedure is performed:

Выделяют m-1 ближайших соседей обрабатываемой точки 304, которые образуют окно визирования m, 305. Затем в определенной m окрестности определяют минимальное и максимальное значение яркости, затем окрестность масштабируется на сегмент [0, 1], 306.The m-1 nearest neighbors of the processed point 304 are selected, which form the sighting window m, 305. Then, in a certain m neighborhood, the minimum and maximum brightness values are determined, then the neighborhood is scaled to the segment [0, 1], 306.

Figure 00000018
,
Figure 00000018
,

где di=Ii,max-Ii,min,where d i = I i, max -I i, min ,

Далее формируют вектор аргументов функции регрессии (S) и вектор (U), 307.Next, a vector of arguments of the regression function (S) and a vector (U), 307, are formed.

Накопление значений аргумента функции (S) и вектора (U), 308.The accumulation of the values of the argument of the function (S) and the vector (U), 308.

После этого, решая СЛАУ, определяют искомый вектор оптимальных коэффициентов K, 309.After that, solving SLAE, the desired vector of optimal coefficients K, 309 is determined.

На Фиг.4 приведена блок-схема этапов процесса интерполяции изображения сплайн-полиномом для случая m=9, t=2, n=2.Figure 4 shows the block diagram of the steps of the process of interpolating the image with a spline polynomial for the case m = 9, t = 2, n = 2.

Вначале необходимо задать масштабный коэффициент интерполяции t, а также в зависимости от требуемой точности и допустимых временных и системных ресурсов определить степень (n) и размерность (m) применяемого интерполяционного полинома, 401.First, it is necessary to set the scale interpolation coefficient t, and also, depending on the required accuracy and acceptable time and system resources, determine the degree (n) and dimension (m) of the applied interpolation polynomial, 401.

В зависимости от выбранных параметров m, t и n загружают рассчитанный ранее вектор коэффициентов полинома K, 401.Depending on the selected parameters, m, t and n load the previously calculated coefficient vector of the polynomial K, 401.

Затем для каждого пикселя исходного изображения I(x, y) 402 выделяют m-1 ближайших соседей, 403. В результате образуется окно визирования размером m, 404. При этом в случае выхода границы окна за пределы интерполируемых данных недостающие пиксели (с отрицательной какой-либо координатой) в простейшем случае дублируют соседними значениями яркости, либо для получения лучших результатов рассчитывают линейной экстраполяцией.Then, for each pixel of the original image I (x, y) 402, m-1 nearest neighbors, 403. are selected. As a result, a sighting window of size m, 404 is formed. In this case, if the window border goes beyond the interpolated data, the missing pixels (with a negative or coordinate) in the simplest case, duplicate adjacent brightness values, or to obtain better results calculated by linear extrapolation.

Затем в полученной m окрестности определяют минимальное и максимальное значения яркости, после этого окрестность масштабируют на сегмент [0, 1], 405.Then, in the obtained m neighborhood, the minimum and maximum brightness values are determined, after which the neighborhood is scaled to the segment [0, 1], 405.

Figure 00000018
,
Figure 00000018
,

где di=Ii,mах-Ii,min,where d i = I i, max -I i, min ,

Далее формируют вектор аргументов функции регрессии, 406.Next, form a vector of arguments of the regression function, 406.

После этого вычисляют полином и находят интерполированные значения пикселя, 407.After that, a polynomial is calculated and the interpolated pixel values, 407, are found.

Затем полученные значения масштабируют обратно на сегмент [localmin, localmin]:Then the obtained values are scaled back to the [local min , local min ] segment:

Figure 00000019
Figure 00000019

После чего полученным интерполированным значениям присваивают соответствующие координаты, 408.After that, the obtained coordinates are assigned the corresponding coordinates, 408.

Описанная процедура, а именно шаги 402-408, производится для каждой цветовой компоненты в пространстве RGB или YCrCb, 410. После того как условие 409 выполнено, изображение поступает на устройство вывода (принтер, дисплей или какое-либо другое) или сохраняется в память.The described procedure, namely steps 402-408, is performed for each color component in the RGB or YCrCb, 410 space. After condition 409 is fulfilled, the image is sent to an output device (printer, display, or some other) or stored in memory.

Фиг.5 иллюстрирует задачу интерполирования изображения в 4 раза двумя способами: бикубическим и новым методом, описанным выше, где 5.1 - исходные изображения, 5.2, 5.4 и 5.6 - изображения, интерполированные способом-прототипом, 5.3, 5.5, 5.7 - изображения, интерполированные заявляемым способом.Figure 5 illustrates the problem of interpolating the image 4 times in two ways: the bicubic and the new method described above, where 5.1 are the source images, 5.2, 5.4 and 5.6 are images interpolated by the prototype method, 5.3, 5.5, 5.7 are images interpolated by the claimed way.

Следует иметь в виду, что указанный выше вариант выполнения изобретения изложен с целью иллюстрации и для специалистов очевидно, что возможны разные модификации, добавления и замены, не выходящие из объема и смысла настоящего изобретения, раскрытого в прилагаемом описании и формуле изобретения. Так, например, модифицировав метод для случая одномерных данных (изображение - двумерное распределение), можно использовать его для обработки звука, а модифицировав метод для случая трехмерных данных, можно использовать его для увеличения временного разрешения видеопоследовательностей. Также можно модифицировать алгоритм для реализации адаптивности метода к локальным особенностям интерполируемого изображения.It should be borne in mind that the above embodiment of the invention is set forth for the purpose of illustration and it is obvious to those skilled in the art that various modifications, additions and substitutions are possible without departing from the scope and meaning of the present invention disclosed in the attached description and claims. So, for example, by modifying the method for the case of one-dimensional data (image - two-dimensional distribution), you can use it to process sound, and by modifying the method for the case of three-dimensional data, you can use it to increase the temporal resolution of video sequences. You can also modify the algorithm to implement the adaptability of the method to local features of the interpolated image.

Claims (6)

1. Способ интерполяции цифрового изображения с увеличением частоты дискретизации в t раз, состоящий из следующих шагов:
осуществляют предварительную обработку изображения;
определяют размер окна визирования m, степень интерполяционного полинома n и масштабный коэффициент t;
считывают вектор коэффициентов К, соответствующий заданной комбинации m, n, t;
определяют для каждого пикселя исходного изображения m-1 ближайших соседей, которые вместе с этим пикселем образуют окно визирования m;
осуществляют нормировку яркости пикселей, образующих окно визирования m до уровня k (k=1);
рассчитывают яркость t2 пикселей с помощью m мерного интерполяционного полинома степени n с фиксированными коэффициентами K вида:
Figure 00000020
где
Figure 00000021
- m мерный полином степени n, v1, v2, … vw образуют вектор V, вид которого определяется данным полиномом, k1, k2, … kw - коэффициенты полинома, образующие вектор K, d(x, y) - масштабный коэффициент для текущего окна, I(х, у) - интерполируемый пиксель изображения;
присваивают каждому интерполированному пикселю новые координаты (х', у');
повторяют все предыдущие шаги для каждой цветовой компоненты;
проводят заключительную обработку изображения для уменьшения артефактов.
1. The method of interpolation of a digital image with an increase in sampling frequency t times, consisting of the following steps:
carry out preliminary image processing;
determine the size of the window of sight m, the degree of interpolation polynomial n and the scale factor t;
reading the coefficient vector K corresponding to a given combination of m, n, t;
determine for each pixel of the original image m-1 the nearest neighbors, which together with this pixel form a window of sight m;
carry out the normalization of the brightness of the pixels forming the sighting window m to the level k (k = 1);
calculate the brightness of t 2 pixels using m dimensional interpolation polynomial of degree n with fixed coefficients K of the form:
Figure 00000020
Where
Figure 00000021
- m dimensional polynomial of degree n, v 1 , v 2 , ... v w form the vector V, the form of which is determined by the given polynomial, k 1 , k 2 , ... k w are the coefficients of the polynomial forming the vector K, d (x, y) - scale factor for the current window, I (x, y) - interpolated image pixel;
Assign new coordinates to each interpolated pixel (x ', y');
repeat all the previous steps for each color component;
perform final image processing to reduce artifacts.
2. Способ по п.1, отличающийся тем, что коэффициенты K m-мерного полинома рассчитывают, исходя из задачи уменьшения частоты дискретизации цифрового изображения в различное число раз и его обратного восстановления с условием близости результата восстановления цифрового изображения исходному цифровому изображению в смысле наименьших квадратов, при этом поиск коэффициентов К проводят с применением метода множественного регрессионного анализа с использованием упомянутого m-мерного кусочно-непрерывного полинома степени n с фиксированными коэффициентами К.2. The method according to claim 1, characterized in that the coefficients K of the m-dimensional polynomial are calculated based on the task of reducing the sampling frequency of the digital image by a different number of times and its reverse recovery with the condition that the result of the restoration of the digital image is similar to the original digital image in the sense of least squares , while the search for the coefficients K is carried out using the method of multiple regression analysis using the aforementioned m-dimensional piecewise continuous polynomial of degree n with fixed oeffitsientami K. 3. Способ по п.1, отличающийся тем, что коэффициенты K определяют с применением множественного регрессионного анализа и набора эталонных изображений, которые искажены по тому же алгоритму, что и обрабатываемое изображение.3. The method according to claim 1, characterized in that the K coefficients are determined using multiple regression analysis and a set of reference images that are distorted by the same algorithm as the processed image. 4. Способ по п.1, отличающийся тем, что параметры полинома фиксированы и не зависят от интерполируемых данных.4. The method according to claim 1, characterized in that the parameters of the polynomial are fixed and independent of the interpolated data. 5. Способ по п.1, отличающийся тем, что в качестве единственного критерия оптимальности принимают минимизацию погрешности масштабирования, для чего предварительно задают масштабный коэффициент интерполяции t, а также в зависимости от требуемой точности и вычислительных возможностей определяют степень (n) и размерность (m) применяемого интерполяционного полинома.5. The method according to claim 1, characterized in that, as the only optimality criterion, minimization of the scaling error is adopted, for which a scale interpolation coefficient t is preliminarily set, and, depending on the required accuracy and computational capabilities, the degree (n) and dimension (m ) applied interpolation polynomial. 6. Способ по п.1, отличающийся тем, что расчет коэффициентов K полинома для каждого варианта интерполяционных параметров, в том числе размера окна визирования, степени полинома, масштабного коэффициента, выполняют один раз, при этом найденные параметры применяют для масштабирования произвольного изображения. 6. The method according to claim 1, characterized in that the calculation of the K coefficients of the polynomial for each variant of the interpolation parameters, including the size of the viewing window, the degree of the polynomial, the scale factor, is performed once, while the found parameters are used to scale an arbitrary image.
RU2007105236/09A 2007-02-13 2007-02-13 Method for digital image interpolation RU2367019C2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
RU2007105236/09A RU2367019C2 (en) 2007-02-13 2007-02-13 Method for digital image interpolation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
RU2007105236/09A RU2367019C2 (en) 2007-02-13 2007-02-13 Method for digital image interpolation

Publications (2)

Publication Number Publication Date
RU2007105236A RU2007105236A (en) 2008-08-20
RU2367019C2 true RU2367019C2 (en) 2009-09-10

Family

ID=39747578

Family Applications (1)

Application Number Title Priority Date Filing Date
RU2007105236/09A RU2367019C2 (en) 2007-02-13 2007-02-13 Method for digital image interpolation

Country Status (1)

Country Link
RU (1) RU2367019C2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10244129B2 (en) 2015-10-12 2019-03-26 Yandex Europe Ag Method of processing and storing images

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5671298A (en) * 1994-08-30 1997-09-23 Texas Instruments Incorporated Image scaling using cubic filters
JP2000207391A (en) * 1998-11-10 2000-07-28 Sony Corp Device and method for interpolation and image display device
US6577778B1 (en) * 2000-01-27 2003-06-10 Myson Century, Inc. Method and apparatus for interpolating a digital image
US6603888B1 (en) * 1998-10-13 2003-08-05 Sony Corporation Interpolating apparatus and method
RU2221275C2 (en) * 1997-07-10 2004-01-10 Самсунг Электроникс Ко., Лтд. Method for interpolating double-tone image
RU2002128369A (en) * 2002-10-23 2004-04-27 Общество с ограниченной ответственностью "Новые Алмазные Технологии" METHOD FOR FLOWER CODE INTERPOLATION AND DEVICE FOR ITS IMPLEMENTATION

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5671298A (en) * 1994-08-30 1997-09-23 Texas Instruments Incorporated Image scaling using cubic filters
RU2221275C2 (en) * 1997-07-10 2004-01-10 Самсунг Электроникс Ко., Лтд. Method for interpolating double-tone image
US6603888B1 (en) * 1998-10-13 2003-08-05 Sony Corporation Interpolating apparatus and method
JP2000207391A (en) * 1998-11-10 2000-07-28 Sony Corp Device and method for interpolation and image display device
US6577778B1 (en) * 2000-01-27 2003-06-10 Myson Century, Inc. Method and apparatus for interpolating a digital image
RU2002128369A (en) * 2002-10-23 2004-04-27 Общество с ограниченной ответственностью "Новые Алмазные Технологии" METHOD FOR FLOWER CODE INTERPOLATION AND DEVICE FOR ITS IMPLEMENTATION

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10244129B2 (en) 2015-10-12 2019-03-26 Yandex Europe Ag Method of processing and storing images

Also Published As

Publication number Publication date
RU2007105236A (en) 2008-08-20

Similar Documents

Publication Publication Date Title
Xu et al. Learning deformable kernels for image and video denoising
US8538201B2 (en) Image resolution enhancement
US7149369B2 (en) Method and system for image scaling
US6058248A (en) Computerized method for improving data resolution
Xu et al. Learning spatial and spatio-temporal pixel aggregations for image and video denoising
US20110243428A1 (en) Bi-Affinity Filter: A Bilateral Type Filter for Color Images
CN111415317B (en) Image processing method and device, electronic equipment and computer readable storage medium
US11854157B2 (en) Edge-aware upscaling for improved screen content quality
Hu et al. Noise robust single image super-resolution using a multiscale image pyramid
JP2008059287A (en) Image processing apparatus and image processing program
CN113012061A (en) Noise reduction processing method and device and electronic equipment
CN111353955A (en) Image processing method, device, equipment and storage medium
JP2020061080A (en) Image processing device, imaging device, and image processing method
US20150324953A1 (en) Method and apparatus for performing single-image super-resolution
JP2020091910A (en) Image processing device, image processing method and program
RU2367019C2 (en) Method for digital image interpolation
CN109410143B (en) Image enhancement method and device, electronic equipment and computer readable medium
JP4687667B2 (en) Image processing program and image processing apparatus
Jiang et al. Antialiased super-resolution with parallel high-frequency synthesis
JP4345027B2 (en) Image processing program and image processing apparatus
Luong et al. Sharp image interpolation by mapping level curves
JP4661754B2 (en) Image processing apparatus and image processing program
Xu et al. Super-resolution via adaptive combination of color channels
KR101730886B1 (en) Processing method for infrared image
Bell et al. Image Processing with Stencil Pipelines

Legal Events

Date Code Title Description
FA94 Acknowledgement of application withdrawn (non-payment of fees)

Effective date: 20081219

FZ9A Application not withdrawn (correction of the notice of withdrawal)

Effective date: 20090129

PD4A Correction of name of patent owner
PC41 Official registration of the transfer of exclusive right

Effective date: 20170921

PD4A Correction of name of patent owner
MM4A The patent is invalid due to non-payment of fees

Effective date: 20200214