1

I'm working on a school project and, between many tasks, I need to binarize Fisher Vectors following what is written in this paper. I was given the vl_feat library to use with Matlab and I implementd this simple tutorial to return fisher vectors given some features.

Everything works fine and I successfully updated the vl_fisher function to raise each dimension of the Fisher vector to the power of a value α ∈ [0, 1] as stated in section 4.1. With α = 0 I can have a Fisher vector with values {-1,0,1} which is a ternary encosing.

The second part of section 4.1 explains how to turn this ternary encoding into an equivalent binary encoding. I got a little lost in there, mainly due to the fact that I'm using a library to return the fisher vector representation. This representation consists of a vector of doubles and it makes it trickier to follow the paper description.

So my question is, how do I binarize fisher vectors with vl_feat library on Matlab ? Do I simply have to binarize the ternary encoding ? Should I compute fisher vectors in another way to make them more suitable for a following binarization ?

Thanks in advance for your time!

G4bri3l
  • 4,996
  • 4
  • 31
  • 53
  • According to the explanation in the paper, it turns out they have done a very simple thing: each element is a factor of multiplication of two signed variables: \delta and w. To make it binary, they seem to have maped possitive values to one, and nonpositive values to 0. Besides, since the values are real numbers, is it really expected to have a high number of 0s in the ternary vector? – Shervin Apr 14 '15 at 17:07
  • I think I'm still missing something, as you stated each element is a factor of multiplication of two signed variables. The first one is encoded as you said, while each dimension of δ is encoded on a single bit based on its sign. There are still a couple complications, vlFeat, given a features vector, returns the fisher representation as an array of doubles. I can get a ternary encoding (alpha =0), but from there I'm not sure how to preceed. I don't think that simply mapping the positive values of the ternary encoding to one and nonpositive to 0 is the way to go, but again I might be wrong. – G4bri3l Apr 15 '15 at 08:17

1 Answers1

1

There are 2 possible solutions to this problem:

  1. You put your hand on the open source library code and make it return what you need
  2. You implement your own way to binarize fisher vectors

I ended up following the second step in Matlab instead of putting my hands on the C library. Keep in mind that this article was very useful when it comes to compute the GMM in the log domain. I'll release my implementation as open source as soon as I'm done with the project.

G4bri3l
  • 4,996
  • 4
  • 31
  • 53