13.08.2018 Views

[Studies in Computational Intelligence 481] Artur Babiarz, Robert Bieda, Karol Jędrasiak, Aleksander Nawrat (auth.), Aleksander Nawrat, Zygmunt Kuś (eds.) - Vision Based Systemsfor UAV Applications (2013, Sprin

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

146 A. <strong>Babiarz</strong>, R. <strong>Bieda</strong>, and K. Jaskot<br />

2.3 Input Image Format<br />

The vision algorithm operates <strong>in</strong> RGB color space. It has the advantage of be<strong>in</strong>g<br />

directly available from the frame-grabber hardware, so there is no need for color<br />

space conversion. Additionally, work<strong>in</strong>g <strong>in</strong> the RGB color space is<strong>in</strong>tuitive and<br />

the visualization and analysis of RGB images and histograms is very easy for<br />

human eye. The RGB color space however is not ideal and suffers from nonl<strong>in</strong>ear<br />

shift of colors happen<strong>in</strong>g after change to the <strong>in</strong>tensity of light. Fortunately, effects<br />

of this undesired shift can be easily removed by the adaptation of the algorithm<br />

which is described below.<br />

In theory, there are other color spaces like HSV or HSL, <strong>in</strong> which color <strong>in</strong>formation<br />

is H and S channels should not be vulnerable to changes <strong>in</strong> the <strong>in</strong>tensity of<br />

light. However, experiments proved that although they really are better than RGB<br />

color space <strong>in</strong> preserv<strong>in</strong>g the color <strong>in</strong>formation unchanged despite of the change of<br />

light<strong>in</strong>g conditions, HSV or HSL histograms also require adaptation, like for<br />

RGB. So there is really no significant advantage of us<strong>in</strong>g these color spaces.<br />

2.4 Adaptation of Background Model<br />

Although the background subtraction algorithm isn’t very sensitive to moderate<br />

changes of ambient light<strong>in</strong>g, it is desirable to give it the ability to update the background<br />

model <strong>in</strong> order to ensure its proper operation dur<strong>in</strong>g long periods of time.<br />

The problem here is not <strong>in</strong> choos<strong>in</strong>g how to update the background (the mov<strong>in</strong>g<br />

average algorithm with learn<strong>in</strong>g factor about 0.1 is good enough) but rather <strong>in</strong><br />

decid<strong>in</strong>g which pixels should be updated. In theory all pixels classified as belong<strong>in</strong>g<br />

to the background should be the subject to update, practice however shows<br />

that this method leads to pollution of background model with pixels com<strong>in</strong>g from<br />

fuzzy edges and from shadow of objects. The solution is to update only pixels<br />

ly<strong>in</strong>g outside of object’s bound<strong>in</strong>g boxes, enlarged twice <strong>in</strong> order to ensure that no<br />

pixels from object’s shadow or fuzzy edge will contribute to the update of background<br />

model. So the whole procedure of the adaptation of background model can<br />

be expressed <strong>in</strong> the formula:<br />

, , , 1 , , , <br />

(8)<br />

, , <br />

where is a set of pairs , be<strong>in</strong>g coord<strong>in</strong>ates of pixels <strong>in</strong> the image, is an<br />

image be<strong>in</strong>g actual background model, is <strong>in</strong>put image, is set of pairs , <br />

be<strong>in</strong>g coord<strong>in</strong>ates of all pixels <strong>in</strong>side two times enlarged bound<strong>in</strong>g boxes, found<br />

by flood fill algorithm. Enlargement is done <strong>in</strong> a way that center of bound<strong>in</strong>g box<br />

rema<strong>in</strong>s <strong>in</strong> the same position. Indexes and 1 denote previous and current<br />

frame, respectively.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!