svmlight problems

asked 2013-10-21 05:15:49 -0600

rokasma gravatar image

Hello,

I am trying to train my hog algorithm and I have one problem. In svm_common.h file I have some ambiguity.

typedef struct word {
  FNUM    wnum;                /* word number */
  FVAL    weight;              /* word weight */
} WORD;

typedef struct svector {
  WORD    *words;    /* Visual Studio 2012 says that WORD is ambiguous */

Where is the problem?

edit retag flag offensive close merge delete

Comments

windef.h , 155 : typedef unsigned short WORD;

so, you must have some windows headers in the way

berak gravatar imageberak ( 2013-10-21 08:47:05 -0600 )edit

What do you mean windows headers?

rokasma gravatar imagerokasma ( 2013-10-23 07:19:23 -0600 )edit

Specific headers to your windows system have the same struct declared as your SVM light implementation. That being said, your compiler is not able to differentiate between both struct implementations. Try adding the namespace of SVM light in front of the line which could actually solve it.

StevenPuttemans gravatar imageStevenPuttemans ( 2014-04-25 06:49:21 -0600 )edit