On Thu, Apr 1, 2010 at 5:52 PM, Barry Haddow <[email protected]> wrote: >> In my feature's FFState implementation, I am currently always returning >> zero from the function virtual int Compare(const FFState& other) const; >> >> Is that the correct way to ensure that for hypothesis recombination, this >> feature will not be taken into account? >> > > Hi Lane > > Yes, I think that's correct. If the Compare() always returns zero, then > recombination will treat all your feature states as equal. Although by the > sound of things your feature is *very* stateful, so you'll end up recombining > states that shouldn't be recombined. >
I'm not intimately familiar with this bit of the code, but a quick look at it suggests that it will do what you want. Formally, what's going on here is that you've got the underlying translation model state, which is just coverage vector C, and you're splitting it with parse state S. A correct dynamic programming state over your full model would be (C, S). What you're planning to do is equivalent to placing each (C, S) in a stack indexed by C with a size of 1 (these stacks live inside *another* stack indexed by |C| with size of the histogram pruning limit). If S is large then the approximation is obviously going to be severe. But, IIRC Michel Galley's dependency translation model from 2009 uses this same trick, although the paper is a bit circumspect about it (in his model, S is basically the entire partial translation produced so far, which is implied by his feature set). http://aclweb.org/anthology-new/P/P09/P09-1087.pdf Cheers Adam _______________________________________________ Moses-support mailing list [email protected] http://mailman.mit.edu/mailman/listinfo/moses-support
