Scaling factor in two matrix

Discuss digital image processing techniques and algorithms. We encourage its application to ImageMagick but you can discuss any software solutions here.
life24
Posts: 22
Joined: 2016-02-19T00:31:25-07:00
Authentication code: 1151

Scaling factor in two matrix

Hello,
I reading an article and i can't understand well about scaling factor.
Could you give me definition and example about scaling factor?
How can embed one matrix to other matrix with scaling factor?
Thanks

fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Scaling factor in two matrix

It might help if you give a reference to that article.

Guess at this point is the the diagonal elements of the D matrix used for the watermarking are scaled (magnified) to enhance the separability of low diagaonal values where the image is flat colored.

life24
Posts: 22
Joined: 2016-02-19T00:31:25-07:00
Authentication code: 1151

Re: Scaling factor in two matrix

Sure,
Reference article is here and we can read it free.
http://www.sciencedirect.com/science/ar ... 0915001945

life24
Posts: 22
Joined: 2016-02-19T00:31:25-07:00
Authentication code: 1151

Re: Scaling factor in two matrix

Emailed to the owner article and answered me, now could you give me more explain about it?

Embedding a matrix into another one can do as matrix addition. Scaling factor is used for obtaining the invisibleness of the watermark. Pls find the below.

Watermarked= A + (s*B).
Here A &B are matrices of cover and watermark. s is the scaling factor. U may vary this according to invisibleness that ur need.

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Scaling factor in two matrix

An image is an array of pixels. It is also a number of arrays of values, where each array represents one channel.

Image arrays can be added together. We can multiply one array by a scalar factor (that is, a single value, like 0.05) before adding it to another.

In IM, "-compose Mathematics" is useful for this.
snibgo's IM pages: im.snibgo.com

life24
Posts: 22
Joined: 2016-02-19T00:31:25-07:00
Authentication code: 1151

Re: Scaling factor in two matrix

We have the below formula

Watermarked= A + (s*B).

If A and B between 0 and 255, for example we have:

S = 0.5 , A = 250 and B = 245

Watermarked = 250 + (0.5*245) = 372.5 !!!
But each pixel is 8-bit and should be between 0 <= intensity <= 255 .

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Scaling factor in two matrix

Well, not exactly. A and B are arrays. So each value in array B is multiplied by s, then added to the corresponding value in B.

Yes, the simple formulae can give overflow (aka clipping). So the array values can be reduced first, or the result is reduced after the calculation, or a different formula used:

out = A*(1-s) + B*s

This is a blending function.
snibgo's IM pages: im.snibgo.com

life24
Posts: 22
Joined: 2016-02-19T00:31:25-07:00
Authentication code: 1151

Re: Scaling factor in two matrix

The below formula is your formula? or it's from other papers?
out = A*(1-s) + B*s

We have out intensity and watermark is fine.
Now with Scale(for example : 0.5 ) and out ,how we can extract A and B ?

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Scaling factor in two matrix

It's a standard blending function. If you know three of the four variables (out, A, B, s) you can easily calculate the fourth, for example:

A = (out - B*s) / (1-s)
snibgo's IM pages: im.snibgo.com

life24
Posts: 22
Joined: 2016-02-19T00:31:25-07:00
Authentication code: 1151

Re: Scaling factor in two matrix

snibgo wrote:It's a standard blending function. If you know three of the four variables (out, A, B, s) you can easily calculate the fourth, for example:

A = (out - B*s) / (1-s)
yes, but when watermark image in the cover image(A and B) , we lost A and B in watermark image.
We just s and out . we don't have A or B.
We don't have B to calculate A. or A to calculate B.We just s and out

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Scaling factor in two matrix

The paper is vague on that. It also says it is "embedded on the singular values of cover image", but there are only 2*min(W+H) non-zero values in the "singular values" matrix. So I don't know how that works.
snibgo's IM pages: im.snibgo.com